| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
| |
See: https://www.gnu.org/licenses/gpl-3.0.html#howto
Run:
$ git grep -l 'Foundation; either version 3' \
| xargs sed -i '/Foundation; either version 3/ s/n; e/n, e/'
* All files using GPLv3: Adjust via the above command.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This lets us simplify cleanup code that calls ‘free’.
* lib/amemxfrm.c (amemxfrm):
* lib/areadlink-with-size.c (areadlink_with_size):
* lib/areadlinkat-with-size.c (areadlinkat_with_size):
* lib/astrxfrm.c (astrxfrm):
* lib/dprintf.c (dprintf):
* lib/execute.c (execute):
* lib/execvpe.c (execvpe):
* lib/fchdir.c (get_name):
* lib/file-has-acl.c (file_has_acl):
* lib/fprintf.c (fprintf):
* lib/getcwd-lgpl.c (rpl_getcwd):
* lib/getgroups.c (rpl_getgroups):
* lib/link.c (link, rpl_link):
* lib/linkat.c (link_immediate, link_follow, linkat_follow):
* lib/localename.c (newlocale, duplocale):
* lib/mgetgroups.c (mgetgroups):
* lib/mountlist.c (read_file_system_list):
* lib/pipe-filter-gi.c (pipe_filter_gi_close):
* lib/putenv.c (_unsetenv, putenv):
* lib/read-file.c (read_file):
* lib/rename.c (rpl_rename):
* lib/savedir.c (streamsavedir, savedir):
* lib/spawni.c (do_open, __spawni):
* lib/spawn-pipe.c (create_pipe):
* lib/striconv.c (mem_cd_iconv, str_cd_iconv, str_iconv):
* lib/striconveh.c (mem_cd_iconveh_internal, str_cd_iconveh)
(mem_iconveh, str_iconveh):
* lib/supersede.c (open_supersede, close_supersede):
* lib/vasnprintf.c (VASNPRINTF):
* lib/vdprintf.c (vdprintf):
* lib/vfprintf.c (vfprintf):
* lib/wcscoll-impl.h (wcscoll):
* lib/wcsxfrm-impl.h (wcsxfrm):
* lib/xgetdomainname.c (xgetdomainname):
* lib/xgethostname.c (xgethostname):
Simplify by assuming that ‘free’ preserves errno.
* lib/localename.c: Do not include errno.h.
* modules/amemxfrm, modules/areadlink-with-size:
* modules/areadlinkat-with-size, modules/astrxfrm:
* modules/c-vasnprintf, modules/dprintf, modules/execute:
* modules/execvpe, modules/fchdir, modules/file-has-acl:
* modules/fprintf-posix, modules/getcwd-lgpl, modules/getgroups:
* modules/link, modules/linkat, modules/localename:
* modules/mgetgroups, modules/mountlist, modules/pipe-filter-gi:
* modules/posix_spawn-internal, modules/putenv, modules/read-file:
* modules/rename, modules/savedir, modules/spawn-pipe:
* modules/striconv, modules/striconveh, modules/supersede:
* modules/vasnprintf, modules/vdprintf, modules/vfprintf-posix:
* modules/wcscoll, modules/wcsxfrm, modules/xgetdomainname:
* modules/xgethostname:
Depend on free-posix.
|
| |
|
|
|
|
|
|
|
|
| |
* lib/areadlink-with-size.c (areadlink_with_size):
* lib/areadlinkat-with-size.c (areadlinkat_with_size):
* lib/careadlinkat.c (readlink_stk):
Do not worry about readlink or readlinkat failing with errno == ERANGE,
since the Gnulib readlink and readlinkat modules now fix that.
|
|
|
|
|
|
| |
* lib/areadlink-with-size.c (areadlink_with_size): Set errno when malloc
fails.
* lib/areadlinkat-with-size.c (areadlinkat_with_size): Add comment.
|
| |
|
|
|
|
|
|
|
| |
* lib/areadlink-with-size.c: Include <string.h>.
* lib/areadlinkat-with-size.c: Likewise.
* lib/xgethostname.c: Likewise.
* lib/xgetdomainname.c: Likewise.
|
|
|
|
|
|
|
|
|
| |
* lib/areadlink-with-size.c (areadlink_with_size):
* lib/areadlinkat-with-size.c (areadlinkat_with_size):
Reallocate at the end to the actual size, to avoid memory waste,
as suggested by Bruno Haible. But when the guessed size is zero -
useful when the size is unknown - do the initial small readlink
into the stack, to avoid that realloc in the usual case.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The size is usually taken from st_size, which can be zero,
resulting in inefficient operation as seen with:
$ strace -e readlink stat -c %N /proc/$$/cwd
readlink("/proc/9036/cwd", "/", 1) = 1
readlink("/proc/9036/cwd", "/h", 2) = 2
readlink("/proc/9036/cwd", "/hom", 4) = 4
readlink("/proc/9036/cwd", "/home/pa", 8) = 8
readlink("/proc/9036/cwd", "/home/padraig", 16) = 13
Instead let zero select an initial memory allocation
of 128 bytes, which most symlinks fit within.
* lib/areadlink-with-size.c (areadlink_with_size):
Start with a 128 byte buffer, for SIZE == 0.
* lib/areadlinkat-with-size.c (areadlinkat_with_size): Likewise.
|
|
|
|
|
| |
* lib/areadlinkat-with-size.c (areadlinkat_with_size): Shrink the buffer
before returning it.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
* build-aux/gendocs.sh (version):
* doc/gendocs_template:
* doc/gendocs_template_min:
* doc/gnulib.texi:
* lib/version-etc.c (COPYRIGHT_YEAR):
Update copyright dates by hand in templates and the like.
* all files: Run 'make update-copyright'.
|
|
|
|
|
|
|
|
|
|
| |
* build-aux/gendocs.sh (version):
* doc/gendocs_template:
* doc/gendocs_template_min:
* doc/gnulib.texi:
* lib/version-etc.c (COPYRIGHT_YEAR):
Update copyright dates by hand in templates and the like.
* all files: Run 'make update-copyright'.
|
|
|
|
|
|
| |
* doc/gnulib.texi:
* lib/version-etc.c (COPYRIGHT_YEAR): Update copyright date.
* all files: Run 'make update-copyright'.
|
|
|
|
|
|
| |
I ran 'make update-copyright'.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
|
|
|
|
|
| |
Run "make update-copyright". Compare to commit 1602f0a from last year.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
|
|
|
| |
Run "make update-copyright".
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* modules/areadlink (Depends-on): Add stdint.
* modules/areadlink-with-size (Depends-on): Likewise.
* lib/areadlink-with-size.c (includes): Drop stdio, since stdlib
gives NULL; drop sys/types, since unistd gives size_t; and add
stdint for SIZE_MAX.
(SIZE_MAX): Rely on headers.
* lib/areadlinkat-with-size.c (includes): Drop stdio, sys/types,
and add stdint.
* lib/areadlink.c (includes): Drop sys/types, and add stdint.
(SIZE_MAX): Likewise.
(INITIAL_BUF_SIZE): Turn into enum.
* lib/areadlinkat.c (INITIAL_BUF_SIZE): Likewise.
Signed-off-by: Eric Blake <ebb9@byu.net>
|
|
* modules/areadlinkat-with-size: New module.
* lib/areadlinkat-with-size.c (areadlinkat_with_size): New file.
* lib/areadlink.h (areadlinkat): Declare it.
* MODULES.html.sh (File system functions): Mention it.
* modules/areadlinkat-with-size-tests: New test.
* tests/test-areadlinkat-with-size.c: New file.
Signed-off-by: Eric Blake <ebb9@byu.net>
|