| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Run "make update-copyright".
|
|
|
|
|
|
|
|
| |
* lib/fclose.c: Include msvc-inval.h.
(fclose_nothrow): New function.
(rpl_fclose): Use it.
* modules/fclose (Depends-on): Add msvc-inval.
* doc/posix-functions/fclose.texi: Mention the problem on MSVC.
|
|
|
|
| |
* lib/fclose.c (rpl_fclose): Don't assume that EOF < 0.
|
|
|
|
|
|
|
|
|
| |
Caught by gcc -Werror=unused-but-set-variable.
* lib/fclose.c (rpl_fclose): Don't lose fflush errors.
Reported by Jim Meyering.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
|
|
|
|
|
|
| |
* lib/fclose.c (rpl_fclose): Invoke _gl_unregister_fd, not
unregister_shadow_fd. Improve comments.
* lib/sockets.c (close_fd_maybe_socket): Add comments. Reported by
Eric Blake.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Calling close(fileno(fp)) prior to fclose(fp) is racy in a
multi-threaded application - some other thread could open a new file,
which is then inadvertently closed by the fclose that we thought
should fail with EBADF. For mingw, this is no worse than the race
already present in close_fd_maybe_socket for calling closesocket()
prior to _close(), but for all other platforms, we might as well be
nice and avoid the race.
* lib/fclose.c (rpl_fclose): Rewrite to avoid double-close race on
all but WINDOWS_SOCKETS.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This fixes the fclose failures detected in the previous patch,
but only when the GPL fflush module is also in use. That is
because the need for behavior of resetting seekable input streams
is much less common, and the fix more complex. The LGPLv2+ test
for fclose() in isolation is relaxed to pass if fflush is not
being replaced to cater to input streams.
* modules/fflush (Depends-on): Add fclose.
* m4/fflush.m4 (gl_FUNC_FFLUSH): Also replace fclose.
* lib/fclose.c (rpl_fclose): Don't cause spurious failures on
memstreams with no backing fd.
* doc/posix-functions/fclose.texi (fclose): Document the use of
fflush module to fix the bug.
* tests/test-fclose.c (main): Relax test when fclose is used in
isolation.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
In an LGPLv2+ project, the last change to fclose dragged in
inappropriate modules.
* modules/fclose (Depends-on): Switch from fflush/fseeko to
simpler lseek.
* lib/fclose.c (rpl_fclose): Likewise.
Reported by Simon Josefsson.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
On mingw, for a project that uses both sockets and streams,
then fclose(stdin) when getting input from a terminal or pipe
was spuriously failing.
* modules/fclose (Depends-on): Add freading, fflush, fseeko.
* lib/fclose.c (rpl_fclose): Skip fflush for non-seekable input,
since fflush is allowed to fail in that case.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
|
|
|
| |
Run the new "make update-copyright" rule.
|
|
|
|
|
| |
Use the same procedure as for 2009, outlined in
http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/20081
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The files named by the following are exempted:
grep -v '^#' config/srclist.txt|grep -v '^$' \
| while read src dst; do
test -f "$dst" && { echo "$dst"; continue; }
test -d "$dst" || continue
echo "$dst"/$(basename "$src")
done > exempt
git ls-files tests/unictype >> exempt
In the remaining files, convert to all-interval notation if
- there is already at least one year interval like 2000-2003
- the file is maintained by me
- the file is in lib/uni*/, where that style already prevails
Otherwise, use update-copyright's default.
|
| |
|
|
|