diff options
| author | Paul Eggert | 2013-07-19 11:09:23 -0700 |
|---|---|---|
| committer | Paul Eggert | 2013-07-19 11:09:23 -0700 |
| commit | 3f5bef16fab0ba83cb2298f8137fec831af1aec4 (patch) | |
| tree | 8f825fe5834080db213452ee3bb1b291f1923a6d /src/ChangeLog | |
| parent | 4195afc389bb0e5ed5aa749e7606a710e07a72d1 (diff) | |
| download | emacs-3f5bef16fab0ba83cb2298f8137fec831af1aec4.tar.gz emacs-3f5bef16fab0ba83cb2298f8137fec831af1aec4.zip | |
Fix some minor file descriptor leaks and related glitches.
* filelock.c (create_lock_file) [!O_CLOEXEC]: Use fcntl with FD_CLOEXEC.
(create_lock_file): Use write, not emacs_write.
* image.c (slurp_file, png_load_body):
* process.c (Fnetwork_interface_list, Fnetwork_interface_info)
(server_accept_connection):
Don't leak an fd on memory allocation failure.
* image.c (slurp_file): Add a cheap heuristic for growing files.
* xfaces.c (Fx_load_color_file): Block input around the fopen too,
as that's what the other routines do. Maybe input need not be
blocked at all, but it's better to be consistent.
Avoid undefined behavior when strlen is zero.
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 73e24bcf829..a63e441dcb2 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,5 +1,18 @@ | |||
| 1 | 2013-07-19 Paul Eggert <eggert@cs.ucla.edu> | 1 | 2013-07-19 Paul Eggert <eggert@cs.ucla.edu> |
| 2 | 2 | ||
| 3 | Fix some minor file descriptor leaks and related glitches. | ||
| 4 | * filelock.c (create_lock_file) [!O_CLOEXEC]: Use fcntl with FD_CLOEXEC. | ||
| 5 | (create_lock_file): Use write, not emacs_write. | ||
| 6 | * image.c (slurp_file, png_load_body): | ||
| 7 | * process.c (Fnetwork_interface_list, Fnetwork_interface_info) | ||
| 8 | (server_accept_connection): | ||
| 9 | Don't leak an fd on memory allocation failure. | ||
| 10 | * image.c (slurp_file): Add a cheap heuristic for growing files. | ||
| 11 | * xfaces.c (Fx_load_color_file): Block input around the fopen too, | ||
| 12 | as that's what the other routines do. Maybe input need not be | ||
| 13 | blocked at all, but it's better to be consistent. | ||
| 14 | Avoid undefined behavior when strlen is zero. | ||
| 15 | |||
| 3 | * alloc.c (staticpro): Avoid buffer overrun on repeated calls. | 16 | * alloc.c (staticpro): Avoid buffer overrun on repeated calls. |
| 4 | (NSTATICS): Now a constant; doesn't need to be a macro. | 17 | (NSTATICS): Now a constant; doesn't need to be a macro. |
| 5 | 18 | ||