diff options
| author | Paul Eggert | 2012-10-12 17:52:01 -0700 |
|---|---|---|
| committer | Paul Eggert | 2012-10-12 17:52:01 -0700 |
| commit | d6453ce49724b0a3bd24922ff0ad02f391d6e517 (patch) | |
| tree | 655b2ca5f792dc2058ad731a4c1bb5af89163b28 /src/ChangeLog | |
| parent | 06485aa8215af39f9f5f999933aa39d349a2bdf9 (diff) | |
| download | emacs-d6453ce49724b0a3bd24922ff0ad02f391d6e517.tar.gz emacs-d6453ce49724b0a3bd24922ff0ad02f391d6e517.zip | |
Fix some stat-related races.
* fileio.c (Fwrite_region): Avoid race condition if a file is
removed or renamed by some other process immediately after Emacs
writes it but before Emacs stats it. Do not assume that stat (or
fstat) succeeds.
* image.c (slurp_file): Resolve the file name with fopen + fstat
rather than stat + fopen.
(pbm_read_file) [0]: Remove unused code with stat race.
* process.c (allocate_pty) [HAVE_PTYS && !PTY_ITERATION && !PTY_OPEN]:
Remove ineffective code with stat race.
Diffstat (limited to 'src/ChangeLog')
| -rw-r--r-- | src/ChangeLog | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index d753221b996..6c03ef0ba0a 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,16 @@ | |||
| 1 | 2012-10-13 Paul Eggert <eggert@cs.ucla.edu> | ||
| 2 | |||
| 3 | Fix some stat-related races. | ||
| 4 | * fileio.c (Fwrite_region): Avoid race condition if a file is | ||
| 5 | removed or renamed by some other process immediately after Emacs | ||
| 6 | writes it but before Emacs stats it. Do not assume that stat (or | ||
| 7 | fstat) succeeds. | ||
| 8 | * image.c (slurp_file): Resolve the file name with fopen + fstat | ||
| 9 | rather than stat + fopen. | ||
| 10 | (pbm_read_file) [0]: Remove unused code with stat race. | ||
| 11 | * process.c (allocate_pty) [HAVE_PTYS && !PTY_ITERATION && !PTY_OPEN]: | ||
| 12 | Remove ineffective code with stat race. | ||
| 13 | |||
| 1 | 2012-10-12 Stefan Monnier <monnier@iro.umontreal.ca> | 14 | 2012-10-12 Stefan Monnier <monnier@iro.umontreal.ca> |
| 2 | 15 | ||
| 3 | * doc.c (get_doc_string): Don't signal an error if the file is missing. | 16 | * doc.c (get_doc_string): Don't signal an error if the file is missing. |