			     BASH PATCH REPORT
			     =================

Bash-Release: 2.05
Patch-ID: bash205-003

Bug-Reported-by: Ian Jackson <ian@davenant.greenend.org.uk>
Bug-Reference-ID: <15047.36587.880816.594177@davenant.relativity.greenend.org.uk>

Bug-Description:

When /tmp is full, and bash is writing a here document whose size is less
than a stdio buffer, write errors can be ignored, leading to loss of the
here document contents.

I have made some other changes to redir.c, so your line numbers will probably
vary slightly.

Patch:

*** ../bash-2.05/redir.c	Tue Mar 27 09:43:50 2001
--- redir.c	Wed Apr 11 15:01:15 2001
***************
*** 290,295 ****
  	    }
  	}
-       fclose (fp);
        dispose_words (tlist);
      }
    return 0;
--- 292,302 ----
  	    }
  	}
        dispose_words (tlist);
+       if (fclose (fp) != 0)
+ 	{
+ 	  if (errno == 0)
+ 	    errno = ENOSPC;
+ 	  return (errno);
+ 	}
      }
    return 0;
