Mini Shell
commit 04a24db27ad1572f766bad772cdd9c146e6d9cf0
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Mar 18 03:17:06 2024 +0100
Release libbsd 0.12.2
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit b62f36f3055262faf28e4ff12dd7ed03c44e09d8
Author: Sam James <sam@gentoo.org>
Date: Wed Mar 13 23:34:55 2024 +0000
test: nlist: make resilient against -Wl,--gc-sections
With linker sections GC enabled, we get a test failure in `nlist.c`:
```
nlist: nlist.c:72: main: Assertion `rc == 0' failed.
```
This turns out to be because several sections used by the test can be discarded:
```
ld: removing unused section '.text.func_pub' in file 'nlist.o'
ld: removing unused section '.bss.data_pub_uninit' in file 'nlist.o'
ld: removing unused section '.data.data_pub_init' in file 'nlist.o'
```
Reproduced with `CFLAGS="-Og -fdata-sections -ffunction-sections"` and
`LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,--gc-sections -Wl,-z,start-stop-gc"`.
Additionally, `LDFLAGS="... -Wl,--print-gc-sections"` can help with diagnosing
which sections get removed.
We already mark these symbols as `used`, but we need `retain` [0] for them
to survive linker GC too.
[0] https://releases.llvm.org/18.1.0/tools/lld/docs/ELF/start-stop-gc.html#annotate-c-identifier-name-sections
Closes: !29
Signed-off-by: Sam James <sam@gentoo.org>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
test/nlist.c | 18 +++++++++++++++---
1 file changed, 15 insertions(+), 3 deletions(-)
commit 2a3d521318533bb1d0535b989be578b4f5c5ff1a
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Mar 14 01:56:36 2024 +0100
build: Do not rely on internal autoconf ac_cv_sys_file_offset_bits variable
This is an internal implementation detail from AC_SYS_LARGEFILE, which
happened to change with autoconf 2.72. Instead compute our own size
for off_t.
Closes: #28
m4/libbsd-large.m4 | 12 +++++++++++-
1 file changed, 11 insertions(+), 1 deletion(-)
commit 149aafe1983893c44265352e47aca1cae73b9508
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Mar 14 01:59:19 2024 +0100
build: Use -eq instead of = as test operators for arithmetic tests
m4/libbsd-large.m4 | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
commit 435825784ffaf7e514558a6537bb53835692ae33
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Mar 13 00:56:59 2024 +0100
build: Fix typo in ABI selection description
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 31e9396bf215cbaf224b99617ef683950f0aae02
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Mar 13 00:56:07 2024 +0100
build: Only install time struct conversion macros where missing
These macros are available in several systems, and we should not install
the man pages for them, otherwise we might end up shadowing the system
man pages if present.
configure.ac | 15 +++++++++++++++
m4/libbsd-compiler.m4 | 16 ++++++++++++++++
man/Makefile.am | 9 +++++++--
3 files changed, 38 insertions(+), 2 deletions(-)
commit 3b8416acabdd6966f70803c756913398e76cb333
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Mar 10 18:01:02 2024 +0100
man: Add links for errc module functions
Reported-by: Alejandro Colomar <alx@kernel.org>
man/Makefile.am | 3 +++
man/verrc.3bsd | 1 +
man/vwarnc.3bsd | 1 +
man/warnc.3bsd | 1 +
4 files changed, 6 insertions(+)
commit 94d0fb3c53faa567f20a20eae12bac7cfdfa2639
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Mar 8 03:05:24 2024 +0100
man: Do not install timeval(3bsd) nor timespec(3bsd)
These are system types, which we should not be documenting. Rewrite the
man pages around the TIMEVAL_TO_TIMESPEC and TIMESPEC_TO_TIMEVAL macros.
man/Makefile.am | 2 -
man/TIMESPEC_TO_TIMEVAL.3bsd | 101 +++++++++++++++++++++++++++++++-
man/TIMEVAL_TO_TIMESPEC.3bsd | 2 +-
man/timespec.3bsd | 1 -
man/timeval.3bsd | 134 -------------------------------------------
5 files changed, 101 insertions(+), 139 deletions(-)
commit e848f5aa298158243bde1c657821a2cdcfc1f88d
Author: Duncan Overbruck <mail@duncano.de>
Date: Tue Mar 5 17:02:32 2024 +0100
strtonum: Do not abort on EINVAL from strtoi()
With musl libc strtoimax(".", ...) returns EINVAL.
Closes: !28
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/strtonum.c | 1 +
1 file changed, 1 insertion(+)
commit ee63bca5258374c93ee2b34459f4ad0c08958daf
Author: Duncan Overbruck <mail@duncano.de>
Date: Tue Mar 5 17:01:29 2024 +0100
closefrom: Ignore files starting with dot when scanning /proc/self/fd
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/closefrom.c | 3 +++
1 file changed, 3 insertions(+)
commit 9cbd935d92d1d5cd72af3c59bb933efa706441b0
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Mar 6 02:12:56 2024 +0100
build: Match also gnu* for GNU/Hurd on the glibc ABI selection
The GNU/Hurd system does not specify a kernel part, so we need to match
on both *-gnu* and gnu* (to avoid overmatching with just *gnu*).
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 70f49a7028adac9ee7e336d8f3b1c16b6636caa6
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 28 04:50:34 2024 +0100
Release libbsd 0.12.1
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit b6ccd032014cdf214e7c8c2b456ca921ba35d8f6
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 28 04:44:02 2024 +0100
build: Add a comment to libbsd-overlay.pc about -isystem usage
Add the reasoning for why we use -isystem instead of -I, to avoid
confusing unsuspecting readers of the file.
Prompted-by: Alejandro Colomar <alx@kernel.org>
src/libbsd-overlay.pc.in | 1 +
1 file changed, 1 insertion(+)
commit 08188f3c13ee2ddd58a62936ff01ccd67bb034d8
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 28 04:37:44 2024 +0100
build: Install err.h if either of the err or errc modules are built
Both modules expose their functions in err.h, so we need to install it
whenever any of them is being built.
Reported-by: Alejandro Colomar <alx@kernel.org>
configure.ac | 6 ++++++
include/Makefile.am | 2 +-
2 files changed, 7 insertions(+), 1 deletion(-)
commit 644062da402bbe9f61905b1c97767b8c75e5d36f
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 27 05:52:53 2024 +0100
Release libbsd 0.12.0
configure.ac | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 32d18dcf47a8ac9f0e21b787bc154f8ca72dbdd8
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Feb 9 04:32:12 2024 +0100
Add explicit time32 and time64 support
Handle the three potential system scenarios:
- system time_t is time64
- system time_t is time32 and supports time64
- system time_t is time32 and does not support time64
Add the explicit time32 and time64 functions when necessary and map
them accordingly for each of these cases.
configure.ac | 1 +
include/Makefile.am | 11 +++
include/bsd/sys/cdefs.h | 4 +
include/bsd/timeconv.h | 13 +++
m4/libbsd-large.m4 | 51 ++++++++++++
src/libbsd.map.in | 11 +++
src/timeconv.c | 208 +++++++++++++++++++++++++++++++++++++++++++-----
test/.gitignore | 2 +
test/Makefile.am | 8 ++
test/timeconv32.c | 43 ++++++++++
test/timeconv64.c | 40 ++++++++++
11 files changed, 371 insertions(+), 21 deletions(-)
commit 605614d6423083863c7c71bf53786bfec77bbf6a
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Feb 12 03:00:06 2024 +0100
build: Add support for AIX
configure.ac | 46 ++++++++++++++++++++++++++++++++++++++++++++++
include/bsd/md5.h | 2 ++
2 files changed, 48 insertions(+)
commit ec7f5ee984c55659f77c73db00457d3bcbeb040c
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Feb 12 01:04:37 2024 +0100
Add vasprintf() and asprintf() functions missing on AIX
These functions are used by code in the library, even though these
functions started as GNU extensions, they are present in all BSDs,
so we expose them as part of our interface on AIX.
COPYING | 2 +-
configure.ac | 8 +++++++
include/bsd/stdio.h | 12 +++++++++-
src/Makefile.am | 7 ++++++
src/asprintf.c | 43 +++++++++++++++++++++++++++++++++++
src/libbsd.map.in | 7 ++++++
src/vasprintf.c | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++
7 files changed, 141 insertions(+), 2 deletions(-)
commit 5392f0c1a44f5898eec4ff6ab0866b2f5c917855
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Feb 12 02:55:08 2024 +0100
build: Add support for Solaris
configure.ac | 45 +++++++++++++++++++++++++++++++++++++++++++++
src/local-link.h | 2 +-
2 files changed, 46 insertions(+), 1 deletion(-)
commit be4aced4c50e3125f95b090c3b6d78f9ccb217a1
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 11 23:55:40 2024 +0100
build: Make almost all exposed interfaces use the new ABI selection
Explicitly select what to include as part of the target ABI, instead of
letting autoconfiguration potentially break ABI if the system grows
functionality provided by the library.
Make almost all the library selectable per target. Do not install manual
pages for interfaces not included in the library. Control inclusion of
symbols in map file via pre-processor macros, and move the comments
describing the ABI selection to configure.ac.
For now the header files are included as is and filtered through
pre-processor conditionals. Eventually they might get switched to be
autogenerated at build time.
configure.ac | 168 +++++++++++++++++++++++++++++++++++++-
include/Makefile.am | 51 ++++++++++--
man/Makefile.am | 228 ++++++++++++++++++++++++++++++++++++++++------------
src/Makefile.am | 194 ++++++++++++++++++++++++++++++++++++--------
src/libbsd.map.in | 118 ++++++++++++++++++++++++---
test/Makefile.am | 86 +++++++++++++++++---
6 files changed, 728 insertions(+), 117 deletions(-)
commit 27503a1066fe28ebc84d080f24a475c99f82b48e
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 14 04:59:44 2024 +0100
build: Rework ABI selection logic
Add a new LIBBSD_SELECT_ABI m4 macro, and use it to setup the ABI
interfaces to expose and the various variables and conditionals
to be used by the build system.
Switch to set the initial values to unknown and then set every one
of the selections explicitly by supported target.
Update comments for rationale for things to DROP, or for why some
selections are enabled.
configure.ac | 96 +++++++++++++++++++++++++++++++++------------------
m4/libbsd-compiler.m4 | 16 +++++++++
2 files changed, 78 insertions(+), 34 deletions(-)
commit 99739877be6e3eaa28681201019ec16788c789fe
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 14 04:59:44 2024 +0100
build: Rename ABI selection variables from need_ to abi_
This should make the purpose of these variables more clear.
configure.ac | 104 ++++++++++++++++++++++++++--------------------------
include/Makefile.am | 4 +-
man/Makefile.am | 20 +++++-----
src/Makefile.am | 30 +++++++--------
test/Makefile.am | 18 ++++-----
5 files changed, 89 insertions(+), 87 deletions(-)
commit 0bdbc0787ef9321e779104b781e9641f002cefc2
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 21 02:29:15 2024 +0100
build: Revert accidental testing aid change
This was accidentally included in the commit, but should have only been
used during development.
Fixes: commit de124dcafac678351366b0572938398ea7ae93e4
Changelog: silent
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit de124dcafac678351366b0572938398ea7ae93e4
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 20 04:28:01 2024 +0100
build: Make digest function checks conditional on their use
The digest function checks where unconditionally requiring the functions
to exist or they would error out. But these functions are not required
on all systems, they depend on the ABI to be exposed.
configure.ac | 32 ++++++++++++++++++++------------
1 file changed, 20 insertions(+), 12 deletions(-)
commit 1d287295146a719585b6c92a57e283ee8bc169a3
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 20 04:13:59 2024 +0100
build: Move ABI selection at the top of configure.ac
Merge the existing host_os block for the OS detection with the ABI
selection one, as these are related. This way we will be able to make
some of the latter checks conditional on the selected ABI.
configure.ac | 116 ++++++++++++++++++++++++++++++-----------------------------
1 file changed, 59 insertions(+), 57 deletions(-)
commit a81d0b711354a9eb2621d67d3a47c2ae5cf33b9e
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 11 23:55:40 2024 +0100
build: Sort variables and their contents in automake files
This should make it easier to add new entries, and find them afterwards.
man/Makefile.am | 48 +++++++++++++++++++-------------------
src/Makefile.am | 64 +++++++++++++++++++++++++-------------------------
test/Makefile.am | 71 +++++++++++++++++++++++++++++++++-----------------------
3 files changed, 98 insertions(+), 85 deletions(-)
commit c8e5338a7c5010d131a920c245d27618b01bde59
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 21 02:05:57 2024 +0100
build: Rename LIBBSD_ABI to SOVERSION
This matches the semantics of the variable, and makes it independent of
the project, just as the package variables.
configure.ac | 10 +++++-----
src/Makefile.am | 2 +-
2 files changed, 6 insertions(+), 6 deletions(-)
commit b6d6da4cd46ac2c20bd8febe935e1af3ae96c4a9
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 20 04:40:32 2024 +0100
build: Refactor function checks into a new libbsd-funcs.m4 file
These are complex enough to clutter the main configure.ac. Move them
into their own file.
configure.ac | 49 ++--------------------------------------------
m4/libbsd-funcs.m4 | 57 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 59 insertions(+), 47 deletions(-)
commit f8cb9d8b28048c76a3a8dd724d28a6ecd130d835
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 20 03:57:37 2024 +0100
build: Remove space before shell redirection
This makes it more clear what the redirection applies to.
man/Makefile.am | 2 +-
src/Makefile.am | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
commit 154624ab459723b204d031405f4321eba83ccc36
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 18 20:40:24 2024 +0100
build: Add support for silent rules for the libbsd.map generation
The new rule was introduced w/o silent rule support.
Fixes: commit 19e06407eb365a2bedc9bdd29a83c1e1803e3f92
src/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 9fab225f2676c1a230bb9ea71a548e3b9796a28d
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Feb 17 05:25:01 2024 +0100
Split errc family of functions from err ones
On most systems the err family of functions is already present, but are
missing the errc family of functions, which are also present on some
other systems. Splitting them into separate files will make it easer to
conditionally include one or the other.
configure.ac | 8 ++++++
man/Makefile.am | 7 ++++-
src/Makefile.am | 13 ++++++++-
src/err.c | 50 +--------------------------------
src/{err.c => errc.c} | 76 ---------------------------------------------------
5 files changed, 27 insertions(+), 127 deletions(-)
commit 461f10ac579f4e997db7493c61b2601c269bef1d
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Feb 17 03:07:58 2024 +0100
Sync strtoi()/strtou() implementations from NetBSD
These contain the fixes to the error handling logic.
In NetBSD the manual page for strtou.3 is generated from the strtoi.3
manual page applying some substitutions, the problem is that the
cross-references are then lost. We will still keep them separate.
Reported-by: Alejandro Colomar <alx@kernel.org>
man/strtoi.3bsd | 22 ++++++++++++++--------
man/strtou.3bsd | 22 ++++++++++++++--------
src/strtoi.c | 20 ++++++++++----------
src/strtonum.c | 28 ++++++++++++++++++++--------
src/strtou.c | 18 +++++++++---------
5 files changed, 67 insertions(+), 43 deletions(-)
commit f0501609764fe1e725c18e847c3904ed3a6544e0
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 14 03:39:16 2024 +0100
build: Swap symbol and alias arguments order in macros creating aliases
The current order is rather confusing, pass the real symbol first
and the alias we want to create next.
src/local-link.h | 26 +++++++++++++-------------
src/md5.c | 18 +++++++++---------
src/setproctitle.c | 6 +++---
src/unvis.c | 4 ++--
src/vis.c | 4 ++--
5 files changed, 29 insertions(+), 29 deletions(-)
commit 19e06407eb365a2bedc9bdd29a83c1e1803e3f92
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 11 19:35:05 2024 +0100
build: Generate the map file from the configured ABI
Some linkers require the map file definitions to contain only symbols
that are present on the linked object, either in the map file or in the
sym file we generate from the map file.
This is preparatory work to be able to conditionally include symbols
in the man and sym files depending on the ABI definitions.
.gitignore | 1 +
src/Makefile.am | 11 +++++++++--
src/{libbsd.map => libbsd.map.in} | 2 ++
3 files changed, 12 insertions(+), 2 deletions(-)
commit 10920c3084446703663ccc1aa4146999dcd61f78
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Feb 12 00:06:56 2024 +0100
build: Make name_from_id man pages conditional instead of id_from_name
The code is only making the name_from_id function conditional, and
assumes id_from_name are always to be included, so we need to match
the logic for the man page inclusion.
configure.ac | 6 +++---
man/Makefile.am | 9 ++++++---
2 files changed, 9 insertions(+), 6 deletions(-)
commit 97b0fe84b855eb8e7eeffaa2f5aacee543bf9fb2
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jan 8 23:57:45 2024 +0100
man: Mention that funopen() can be made available on musl
As musl got fopencookie() implemented in 1.1.19, the funopen() function
can also be provided there. Note this in the documentation.
man/funopen.3bsd | 9 ++++-----
man/libbsd.7 | 2 +-
2 files changed, 5 insertions(+), 6 deletions(-)
commit e87ae3be195a84272ce422694761fc6d414581d1
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jan 8 23:40:31 2024 +0100
man: Fix manual page references
When referring to another manual page and their section number, we need
to use Xr instead of Fn, otherwise the section number is interpreted as
a function argument. For functions provided by libbsd itself we should
be using the 3bsd section instead of 3.
man/libbsd.7 | 50 +++++++++++++++++++++++++-------------------------
1 file changed, 25 insertions(+), 25 deletions(-)
commit 9275d134e5f6101a4cf2e31cd2298605afe0a052
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jan 8 23:39:19 2024 +0100
man: Add closefrom(), strlcpy() and strlcat() as superseded functions
These were missing from the list of functions provided by some libc
implementation.
man/libbsd.7 | 15 +++++++++++++--
1 file changed, 13 insertions(+), 2 deletions(-)
commit 304a1f831c4132780bb47433d76e6169872cefbc
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jan 8 23:37:43 2024 +0100
doc: Use macOS to refer to the operating system
This is the correct spelling, instead of capitalizing it.
include/bsd/vis.h | 2 +-
man/libbsd.7 | 2 +-
src/unvis.c | 2 +-
src/vis.c | 2 +-
4 files changed, 4 insertions(+), 4 deletions(-)
commit edddd806dfb8c5be0459d66fd9845a11032bf472
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jan 8 02:16:12 2024 +0100
Release libbsd 0.11.8
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit dd0bdb58e0e5b3b811958a1f9ccd7da6d46c9581
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jan 8 01:58:54 2024 +0100
test: Close all descriptors before initializing them for closefrom()
On macOS, closefrom() only sets the close-on-exec flag, so we cannot
check whether all file descriptors were closed, which means that if
on entry our file descriptor table was filled after the 4th file
descriptor, then we might fail the assertions for the flags for odd
file descriptors which we expect to be closed.
This can easily happen when running the test suite in parallel mode
with «make -j8 check» for example.
Closes: #23
test/closefrom.c | 6 ++++++
1 file changed, 6 insertions(+)
commit 0813f3786f4968e4fca374fd7b74fb97a0f51f21
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Oct 28 00:52:31 2023 +0200
build: Check out-of-tree builds in CI
Make sure the out-of-tree builds do not regress.
.gitlab-ci.yml | 11 +++++++++++
1 file changed, 11 insertions(+)
commit df116b5597ae1b17b5b31834c6c082d57ddf94d4
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jan 7 17:43:12 2024 +0100
Adjust strlcpy() and strlcat() per glibc adoption
These functions were added in glibc 2.38, in anticipation of POSIX
adopting them too.
Closes: #26
configure.ac | 5 +++++
include/bsd/string.h | 3 ++-
man/strlcpy.3bsd | 7 ++++---
3 files changed, 11 insertions(+), 4 deletions(-)
commit ecb44e165514885648240c1b139c4ab0c212a0fa
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Nov 14 19:15:11 2023 +0100
Do not add a pointer to the NULL constant
Warned-by: cppcheck (nullPointerArithmetic)
src/merge.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
commit 459b7f7d24069674a63913d03e35586b484dbb95
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Nov 14 19:09:25 2023 +0100
Do not confuse code analyzers with out-of-bounds array access look alike
The code is only getting the address, but we might be performing an
addressing that is out-of-bounds. Avoid it and use the address form
instead.
Warned-by: cppcheck (objectIndex)
src/setproctitle.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit a44f885cd476faee2154cbae1a1dc47bdeaea727
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Nov 14 19:08:15 2023 +0100
test: Fix short-lived memory leak
Warned-by: cppcheck
test/pwcache.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
commit 3f5ca0aae4ce26d0e2bb2a9f908ccdab84638574
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Oct 28 00:47:26 2023 +0200
build: Add a coverage regex to the CI job
This is needed so that gitlab can know where to extract the coverage
percentage from in the output, to be able to track and report it.
.gitlab-ci.yml | 1 +
1 file changed, 1 insertion(+)
commit 9d3e59a01d612e311bdb96d16d436b4b7db9c691
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Oct 10 01:53:32 2023 +0200
man: Use VARIANTS instead of ALTERNATIVES in libbsd(7)
Using alternatives seems confusing in this context.
man/libbsd.7 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit f02562d64aeef86c607a5f876be7a71c5fa9f021
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Oct 10 01:52:37 2023 +0200
man: Markup function references with Xr instead of Fn
These references had man page sections in them, so using Fn meant that
these appeared as function arguments.
man/libbsd.7 | 22 +++++++++++-----------
man/strtoi.3bsd | 2 +-
man/strtonum.3bsd | 8 ++++----
man/strtou.3bsd | 2 +-
4 files changed, 17 insertions(+), 17 deletions(-)
commit b7367c9ced9a0a69ce28bcaf319d50649a41a483
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Sep 5 03:02:44 2023 +0200
build: Add missing dash to macro title bar
m4/libbsd-compiler.m4 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 6777eb62b8ee2b569454dc9b1d27e51a7dbf8764
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jul 27 13:57:51 2023 +0200
pwcache: Do not declare uidtb and gidtb when not used
When the system provides implementations for user_from_uid() or
group_from_gid() we are not using these variables, so better not declare
them.
Fixes: commit 21d12b02112097f0c195dceb1892c95b7b957b36
src/pwcache.c | 4 ++++
1 file changed, 4 insertions(+)
commit d4e0cdc916476fb774b02a7da606e30e367f3f42
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jul 27 13:39:00 2023 +0200
fgetln: Include <stdio.h> after <sys/*>
The <sys/*> headers tend to define things that might be used by other
headers, so while they should be self-contained, it is better to simply
include them first.
src/fgetln.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
commit f41d6c12aacabc3dae5fdd45c50de6a967af8a88
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 26 23:55:40 2023 +0200
build: Refactor GNU .init_array support check into a new m4 function
configure.ac | 44 +-------------------------------------------
m4/libbsd-compiler.m4 | 48 ++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 49 insertions(+), 43 deletions(-)
commit 30b48ed9ea677e604bc47de421983410c3dcf714
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 26 23:50:10 2023 +0200
build: Refactor linker script detection into a new m4 function
configure.ac | 23 +----------------------
m4/libbsd-linker.m4 | 27 +++++++++++++++++++++++++++
2 files changed, 28 insertions(+), 22 deletions(-)
commit d0d8d0197f2d7bedaf02b5ef1ab0db20b61c9588
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jul 27 13:51:36 2023 +0200
build: Do not provide prototypes for arc4random() on Solaris
These functions are provided by the system.
include/bsd/stdlib.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit cf61ebb8455aa96b69dde1d19b1d09b17c0bd1e7
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Apr 22 20:47:20 2023 +0200
build: Do not build the progname module if it is not needed
This was made conditional, but the code part was accidentally left
untouched due to having ported it locally to use __progname, which
caused build failures on the stock repo.
Fixes: commit 046621d7967e7a0f08ae988bcf7e4cd1b6cf204c
src/Makefile.am | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
commit 73b25a8f871b3a20f6ff76679358540f95d7dbfd
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Apr 23 02:04:47 2023 +0200
build: Sort entries alphabetically
man/Makefile.am | 2 +-
src/Makefile.am | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
commit 5434ba169bddb985ca7d0b8f1635b105b0038643
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Apr 23 02:05:04 2023 +0200
build: Conditionalize wcslcpy() and wcslcat() functions on macOS
These functions are provided by the system libc.
configure.ac | 3 +++
include/bsd/wchar.h | 2 ++
man/Makefile.am | 9 +++++++--
src/Makefile.am | 9 +++++++--
4 files changed, 19 insertions(+), 4 deletions(-)
commit dc1bd1a2cbead8a75febae0514904674bbfbf1ed
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Apr 23 02:00:10 2023 +0200
build: Conditionalize only id-from-name functions not the entire pwcache
On macOS the name-from-id functions are present, but not the
id-from-name ones, so we want to provide those instead of suppressing
the entire file.
configure.ac | 6 +++---
man/Makefile.am | 8 ++++----
src/Makefile.am | 7 +------
test/Makefile.am | 5 +----
4 files changed, 9 insertions(+), 17 deletions(-)
commit edc746ea7b8725578e8533b094d40c2be5c04b8b
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Apr 22 22:47:10 2023 +0200
build: Conditionalize getprogname()/setprogname on macOS
These functions are provided by the system libc, so there is no need for
us to provide them.
configure.ac | 3 +++
include/bsd/stdlib.h | 2 ++
man/Makefile.am | 9 +++++++--
test/Makefile.am | 5 ++++-
4 files changed, 16 insertions(+), 3 deletions(-)
commit 8f998d1d204c7a6218b49b021b74e6ac2e8fc642
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Apr 22 20:23:08 2023 +0200
progname: Include <procinfo.h> if available
We need this header on AIX. Missed transplanting the code from the AIX
porting system.
Fixes: commit 9fa06763a1afe0946a3a20e5bbdba72885cbade5
configure.ac | 1 +
src/progname.c | 3 +++
2 files changed, 4 insertions(+)
commit d08163b4fe4e74f02b74a1fb69484b00950a149f
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Apr 18 03:56:16 2023 +0200
build: Check whether we need libperfstat on AIX
The getentropy() implementation makes use of this library on AIX.
configure.ac | 9 +++++++++
1 file changed, 9 insertions(+)
commit 1186cf8822752dfadaf57a78f6b6bb5446f86006
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Apr 18 03:59:17 2023 +0200
build: Annotate droppable functions for musl on next SOVERSION bump
These are already provided by the musl libc, and can thus be dropped on
the next SOVERSION bump.
configure.ac | 6 ++++++
1 file changed, 6 insertions(+)
commit 6385ccc97778f85a61fef503d7661ec6f4e41446
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Apr 18 03:58:24 2023 +0200
build: Conditionalize bsd_getopt() on macOS
The system library provides a getopt() with BSD semantics.
configure.ac | 3 +++
include/bsd/unistd.h | 2 ++
src/Makefile.am | 7 ++++++-
3 files changed, 11 insertions(+), 1 deletion(-)
commit c12068179c252911af95368933605b2cfc5da2d2
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Apr 18 00:47:12 2023 +0200
Move the version script comments before the symbols
When generating the .sym export file from the .map file, we are not
stripping these comments that are part of the same line as the symbol,
which causes ld(1) implementations to error out. Moving them before
the symbols avoids the need to strip them, as we are only keeping
actual symbol lines.
src/libbsd.map | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
commit 9fa06763a1afe0946a3a20e5bbdba72885cbade5
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Apr 18 00:44:49 2023 +0200
Port getprogname() to AIX
Get the program name from the COMM field from the proc filesystem.
We could use instead the information from the psinfo binary file under
/proc, but that seems to have a shorter string limit.
src/progname.c | 8 ++++++++
1 file changed, 8 insertions(+)
commit 92337b15a2414c5ead6dde55b366687ec464b847
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Apr 17 23:59:03 2023 +0200
Make getprogname() porting mandatory
Although the function is documented as possibly returning NULL if it
cannot find a known source of information, we should still at least
attempt to port it to any supported system, and otherwise explicitly
mark it as not implementable for such systems if that was to be the
case.
src/progname.c | 2 ++
1 file changed, 2 insertions(+)
commit 90b7f3aeba2805e06181286b442429b136540214
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Apr 17 23:59:19 2023 +0200
test: Do not use /dev/null as compiler output file
Some ld(1) implementations, such as the one on AIX, do not support using
/dev/null as the output filename for the compiled object.
Use an actual filename that we will then clean up.
test/headers-overlay.sh | 3 ++-
test/headers-system.sh | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
commit 426bf45278cf3edf228b9aa0e3319e7070fc1b57
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Apr 18 00:49:09 2023 +0200
build: Add generated *.sym files to .gitignore
.gitignore | 1 +
1 file changed, 1 insertion(+)
commit 21d12b02112097f0c195dceb1892c95b7b957b36
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Apr 4 23:59:05 2023 +0200
build: On macOS do not build functions provided by the system
We have never built before on macOS, so we can exclude all the functions
that are currently provided in the system.
Closes: #1
Closes: !3
configure.ac | 33 +++++++++++++++++++++++++---
include/Makefile.am | 14 ++++++++++--
include/bsd/grp.h | 2 ++
include/bsd/pwd.h | 2 ++
include/bsd/stdlib.h | 2 ++
include/bsd/string.h | 4 ++++
man/Makefile.am | 52 +++++++++++++++++++++++++++++++++----------
src/Makefile.am | 62 ++++++++++++++++++++++++++++++++++++++++------------
src/pwcache.c | 8 +++++++
test/Makefile.am | 32 ++++++++++++++++++++++-----
test/overlay.c | 2 ++
11 files changed, 177 insertions(+), 36 deletions(-)
commit bc65806ce22a6f838c8788435aea298e1a499c75
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Apr 6 23:05:27 2023 +0200
build: Select whether to include funopen() in the build system
This makes sure we include it when expected, alongside the man pages,
and the test cases, and do not accidentally break the ABI if the system
starts providing such interface.
configure.ac | 26 +++++++++++++++++++++++++-
man/Makefile.am | 7 ++++++-
src/Makefile.am | 7 ++++++-
src/funopen.c | 2 +-
test/Makefile.am | 2 +-
5 files changed, 39 insertions(+), 5 deletions(-)
commit 8b7a4d9d3b444681e14cdb085c25d5217da82c8b
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Apr 7 23:43:55 2023 +0200
build: Move Windows OS detection to the OS features section
This was placed here to make use of the same AS_CASE, but it does not
really fit with the section. Move it to the more appropriate place, and
detangle the AS_CASE.
configure.ac | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
commit ccbfd1c2414d8351a22f3f890994404c50a4b8df
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Apr 7 23:40:22 2023 +0200
build: Remove __MUSL__ definition from configure
We stopped relying on this macro when we turned the funopen() cpp error
into a warning in commit e50896286cc5718898194edb73fa7262ad9a22db.
configure.ac | 4 ----
1 file changed, 4 deletions(-)
commit e0976d7e909382fa4924879f3bdfd9ee1b4549a3
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Apr 2 22:33:25 2023 +0200
build: Add a new libbsd_strong_alias() macro and switch users to it
We had several cases of code needing a strong alias, so we switch those
to use the new macro. This covers systems that support the alias
attribute and others such as macOS where we need to use assembler
directives to add the alias as the attribute is not supported.
src/local-link.h | 12 +++++++++++-
src/setproctitle.c | 6 ++----
2 files changed, 13 insertions(+), 5 deletions(-)
commit 49c7dd1ca487e71cfb3c324fe76562424213b4bc
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Apr 2 22:32:11 2023 +0200
build: Only emit link warnings for ELF objects
src/local-link.h | 4 ++++
1 file changed, 4 insertions(+)
commit 8622767a8abff67877d0989131e64254a9a505bf
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Apr 11 00:24:13 2023 +0200
build: Use an export symbols file if there is no version script support
We generate the symbol list from the version script to avoid repeating
ourselves and potentially getting the lists out-of-sync.
src/Makefile.am | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
commit 8f61036467428e6c00c0aef1943cd4e4b485a90a
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Apr 11 03:03:54 2023 +0200
build: Add -no-undefined libtool flag
We have no need for undefined symbols, so we can let the shared
library build even on systems without support for undefined symbols.
src/Makefile.am | 1 +
1 file changed, 1 insertion(+)
commit ae7942ba6d4f09f084456dabddff04377f39bec9
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Apr 11 03:02:30 2023 +0200
build: Do not override the default DEPENDENCIES for libbsd
Extend it instead via EXTRA_*_DEPENDENCIES, to make sure that we
preserve the builtin library dependencies generated from LIBADD.
src/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit a5faf17090b031b49bb8105d77b7f8b9f1ad671d
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Apr 1 12:46:49 2023 +0200
Only use <stdio_ext.h> if present
configure.ac | 1 +
src/fpurge.c | 2 ++
2 files changed, 3 insertions(+)
commit 06e8a1b29bea85fb3daeb1e3c7393bc78a8dffdb
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Apr 1 12:45:04 2023 +0200
Define _NSIG if it is not defined by the system
At least on macOS this macro is not defined.
src/readpassphrase.c | 9 +++++++++
1 file changed, 9 insertions(+)
commit 44824aca3cae1a3908f80216ff8e53f859d16dc4
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Apr 1 12:41:42 2023 +0200
Declare environ if the system does not do so
The environ variable is supposed to be defined by the code using it, but
on glibc-based systems it will get defined if we request it, by including
<unistd.h> and defining _GNU_SOURCE.
configure.ac | 4 ++++
src/setproctitle.c | 4 ++++
2 files changed, 8 insertions(+)
commit 1fb6c3f4ce2ebd43312f182a77ee407408002cc8
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Apr 10 23:10:40 2023 +0200
Use lockf() when flock() is not available
On Solaris flock() is not available, and we should use instead lockf()
or fcntl().
configure.ac | 1 +
src/flopen.c | 29 +++++++++++++++++++++++------
2 files changed, 24 insertions(+), 6 deletions(-)
commit fe16f3863ec9be8d571d9e53701c9af40f399e4d
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Apr 10 23:11:33 2023 +0200
test: Use open_memstream() only if available
On Solaris this function is not yet available.
configure.ac | 1 +
test/fpurge.c | 31 ++++++++++++++++++++-----------
2 files changed, 21 insertions(+), 11 deletions(-)
commit 7c652a94ea429576b4c10869a7474d40f202b9f3
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Apr 10 20:57:14 2023 +0200
test: Do not hardcode root:root user and group names
On some systems the root group is named wheel, and there is no root
group.
test/pwcache.c | 34 +++++++++++++++++++++++++++++-----
1 file changed, 29 insertions(+), 5 deletions(-)
commit ed2eb31da97331234bb12d70c1c16cae707d7f97
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Apr 1 02:46:22 2023 +0200
test: Fix closefrom() test on macOS
On macOS we do not close the file descriptors, and instead mark them all
as close-on-exec. So checking whether they are not valid does not work.
test/closefrom.c | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
commit 0f8bcdfd92dc6342564192d707f339855c6fbc5f
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Apr 1 02:48:47 2023 +0200
test: Fix closefrom() test to handle open file descriptor limits
If the system has configured a lower limit (either soft or hard) on the
number of open file descriptors, the test will fail. Make sure to check
whether we have exceeded that limit and adapt the max number of file
descriptors appropriately.
test/closefrom.c | 16 +++++++++++++---
1 file changed, 13 insertions(+), 3 deletions(-)
commit 07192b31e3cd4e541bc76b45788cf5e5e8faff9f
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Apr 5 00:01:42 2023 +0200
test: Disable blank_stack_side_effects() on non-Hurd systems
This code was added to cope with Hurd specific behavior, but it is
causing flakiness on containers on some Linux systems. Only enable
it where it is currently needed to try to get stability back on CI
systems.
Closes: #14
test/explicit_bzero.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit ca3db5e134d3a4467ab6916ba271a8d7de75661e
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Mar 29 09:35:27 2023 +0200
build: Do not enable ASAN for musl CI pipelines
musl-libc does not currently support ASAN, so enabling it makes
configure fail to detect libmd as it cannot link to it anymore.
.gitlab-ci.yml | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
commit ff46386fcbb786e61ef94a88ba11bf91ef373424
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Mar 29 02:32:37 2023 +0200
man: Add HISTORY section to arc4random(3bsd)
man/arc4random.3bsd | 13 +++++++++++++
1 file changed, 13 insertions(+)
commit 4c6da577a11bc6857a4dba3a9ce2f6894af1e604
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Mar 29 02:28:52 2023 +0200
man: Switch arc4random(3bsd) man page from OpenBSD to NetBSD
This gets rid of the last BSD-4-clause licensed file in the project.
The man page will probably need to be adapted to the current
implementation, but that can be done piecemeal afterwards.
Closes: #7
COPYING | 38 +-----
man/arc4random.3bsd | 380 ++++++++++++++++++++++++++++++++++++++--------------
2 files changed, 285 insertions(+), 133 deletions(-)
commit 830dd88a986f46f089bf5609b9a06d94427efa4a
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Mar 14 01:58:40 2023 +0100
doc: Remove written-by attribution
While attribution is important, it is not relevant when tracking the
copyright holders for the work. And in any case it still stays in the
relevant source file.
COPYING | 1 -
1 file changed, 1 deletion(-)
commit 257800a03c6b1737c876817a25e8c4bb9258a3ee
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Feb 20 22:23:40 2021 +0100
build: Add support for sanitizer compiler flags
.gitlab-ci.yml | 2 +-
configure.ac | 12 ++++++++++++
2 files changed, 13 insertions(+), 1 deletion(-)
commit 536a7d42fd010811aba208eef281916f34387e78
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Mar 21 04:11:03 2023 +0100
test: Exempt blank_stack_side_effects() from sanitizer checks
This will mean we cannot use sanitizer support on the Hurd, for which
this function was added to fix the test. But the sanitizer suppression
function attribute is not having any effect, so this is better than
nothing.
test/explicit_bzero.c | 2 ++
1 file changed, 2 insertions(+)
commit 7ed5de01583ea99488d8655d7c95a5c2a84cc6d9
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Mar 21 04:10:33 2023 +0100
test: Import explicit_bzero() sanitizer support changes from OpenBSD
test/explicit_bzero.c | 15 +++++++++++++--
1 file changed, 13 insertions(+), 2 deletions(-)
commit 05a802a2c1f9197722e480d3430c24fbfcaf5400
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Mar 14 03:05:58 2023 +0100
test: Fix memory leaks in fpurge test
Warned-by: gcc -fsanitize=leak
test/fpurge.c | 23 ++++++++++++++++-------
1 file changed, 16 insertions(+), 7 deletions(-)
commit 5962e03c2d258269946588f034bb9ce35c868a1c
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Mar 3 01:27:31 2023 +0100
man: Fix BSD and glibc versions
The versions used in the BSD macros are unknown, so they emit warnings,
extend or reduce them to use the two digit form. Correct the glibc
version when closefrom(3) got introduced.
man/closefrom.3bsd | 4 ++--
man/wcslcpy.3bsd | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
commit 59a21c7fb846c483460979be74c546edab0d185e
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Feb 20 00:11:10 2023 +0100
man: Update STANDARDS and HISTORY sections
Include BSD versions when functions were introduced. Add mention
whether these are BSD extensions.
man/arc4random.3bsd | 6 ++++++
man/closefrom.3bsd | 13 +++++++++++--
man/fparseln.3bsd | 4 +++-
man/getpeereid.3bsd | 5 ++++-
man/humanize_number.3bsd | 4 +++-
man/pidfile.3bsd | 14 ++++++++++++++
man/pwcache.3bsd | 6 +++---
man/readpassphrase.3bsd | 6 ++++--
man/reallocarray.3bsd | 10 ++++++++--
man/setproctitle.3bsd | 2 ++
man/strlcpy.3bsd | 2 ++
man/strnstr.3bsd | 5 +++++
man/strtonum.3bsd | 4 ++--
man/tree.3bsd | 3 +++
man/wcslcpy.3bsd | 11 +++++++++++
15 files changed, 81 insertions(+), 14 deletions(-)
commit 7b4ebd6521a693f236cad4170fce1bb5237ecae5
Author: Callum Farmer <callumjfarmer13@gmail.com>
Date: Thu Feb 16 21:26:05 2023 +0000
include: Adjust closefrom() per glibc adoption
Added in glibc 2.34
https://sourceware.org/git/?p=glibc.git;a=commit;h=607449506f197cc9514408908f41f22537a47a8c
Signed-off-by: Guillem Jover <guillem@hadrons.org>
include/bsd/unistd.h | 4 ++++
1 file changed, 4 insertions(+)
commit 0dfbe7699e10a4e68859eba6a878524002bdb5c5
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Feb 17 22:28:45 2023 +0100
build: Switch to debian:latest Docker image
This should always point to the latest Debian stable images.
.gitlab-ci.yml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit dec783dce5a7131e232a06e63a544645b5463dd8
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 12 23:55:09 2023 +0100
build: Fix version script linker support detection
When the linker uses --no-undefined-version either specified by the user
or as the default behavior (such as with newer clang >= 16 releases),
a missing symbol definition will cause a linker error if that symbol is
listed in the version script.
configure.ac | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
commit fe21244b055dbcf3805d105f48437f36db2f25be
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Dec 20 22:47:02 2022 +0100
include: Use __has_builtin to detect __builtin_offsetof support
The __has_builtin operator is more specific and is supported by GCC
and Clang, while __is_identifier() is less specific and only supported
by Clang, so we should prefer the former whenever it is available, and
only fallback to use the latter when the former is missing and the
latter.
include/bsd/sys/cdefs.h | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
commit ec88b7bbbc9ef262b22302419ae14fce5fc7b1d8
Author: Khem Raj <raj.khem@gmail.com>
Date: Thu Dec 15 09:02:22 2022 -0800
funopen: Replace off64_t with off_t in funopen_seek()
AC_SYS_LARGEFILE in configure.ac is setting needed defines to make
64bit off_t on relevant platforms.
Fixes build on musl:
| src/funopen.c:68:28: error: unknown type name 'off64_t'; did you mean 'off_t'?
| funopen_seek(void *cookie, off64_t *offset, int whence)
| ^~~~~~~
| off_t
Closes: !24
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/funopen.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 23377191e85267c091d8ae79cb1dd5c21a6cf305
Author: Guilherme Janczak <guilherme.janczak@yandex.com>
Date: Wed Dec 7 04:06:37 2022 +0000
man: Prune unneeded <sys/types.h> include in setproctitle(3)
FreeBSD first declared the function in unistd.h in 2000:
https://cgit.freebsd.org/src/commit/include/unistd.h?id=9feac5c21886
No other #include line was needed to use the function, but the man page
unnecessarily instructed users to include sys/types.h until 2022-11-29:
https://cgit.freebsd.org/src/commit/?id=5b6f0a5012e9bc37dcb32b57b41e2443a46da620
libbsd first declared the function in unistd.h in 2010 with commit
3fed78e5b08f78256e533788b4bcd6502b0949d7 and inherited the bug from
FreeBSD's man page.
No need to do anything for backwards compat.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
man/setproctitle.3bsd | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
commit 5dea9da38d9e657c10de099bce68c12fc38a39dc
Author: Florian Weimer <fweimer@redhat.com>
Date: Tue Dec 13 03:37:06 2022 +0100
build: Improve C99 compatibility of __progname configure check
The check uses printf, so it needs to include <stdio.h> for
compilers which do not support implicit function declarations.
(They were removed from C99.)
Closes: !23
Signed-off-by: Guillem Jover <guillem@hadrons.org>
configure.ac | 1 +
1 file changed, 1 insertion(+)
commit b9bf42ddc3c428c7d31f1fbf68bdf6e6542f1bbe
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Dec 13 03:35:05 2022 +0100
build: Enable -Wall for automake
This will make sure to warn about bogus or deprecated constructs.
configure.ac | 1 +
1 file changed, 1 insertion(+)
commit e57c07875c6d7f85562c028f2a9eb8490ab94333
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Dec 13 03:34:37 2022 +0100
build: Add missing AM_PROG_AR macro call to configure.ac
Warned-by: autoreconf
configure.ac | 1 +
1 file changed, 1 insertion(+)
commit 80f1927dcd3a2541f6aa74b0c9fa21446253d13a
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Dec 13 03:31:38 2022 +0100
build: Fix configure.ac indentation
Use the same style as the newly added code, which should make the code
more readable, and produce more conforming C output.
configure.ac | 204 +++++++++++++++++++++++++++++++++++------------------------
1 file changed, 120 insertions(+), 84 deletions(-)
commit b7a8bc22c998f99756aa012197870a94d2f3df96
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Dec 13 03:10:28 2022 +0100
build: Require automake 1.11
This is a rather old release (from 2009), that provides AM_SILENT_RULES.
configure.ac | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
commit e50896286cc5718898194edb73fa7262ad9a22db
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Nov 23 23:31:54 2022 +0100
build: Do not require funopen() to be ported
This function cannot be easily and (more importantly) correctly ported
without cooperation from the libc stdio layer. We already document that
users should be prepared to have the function not available on some
platforms and that they should ideally switch their code to other
more portable and better interfaces.
Instead of making the build fail, and requiring porters to add
exceptions for something that most probably cannot be ported correctly
anyway, simply print a warning and let it build. This will not be a
regression because on those systems libbsd would have never been built
before.
Prompted-by: Jens Finkhaeuser <jens@finkhaeuser.de>
configure.ac | 1 +
man/funopen.3bsd | 6 +++++-
src/funopen.c | 8 +-------
test/Makefile.am | 5 ++++-
4 files changed, 11 insertions(+), 9 deletions(-)
commit 00b538ffa3492053b03771b7bc76563d740c038d
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Nov 23 23:28:34 2022 +0100
build: Terminate lists in variables with «# EOL»
This means we can add a trailing «\» to every element, so that they
can be removed without requiring modification of other lines, and can
be easily sorted.
Replace the old usage of $(nil) which could possibly end up with junk
added if such variable is ever defined, in the environment.
Makefile.am | 9 +++++++--
include/Makefile.am | 2 +-
man/Makefile.am | 6 +++---
src/Makefile.am | 28 ++++++++++++++++------------
test/Makefile.am | 16 +++++++++-------
5 files changed, 36 insertions(+), 25 deletions(-)
commit 5cfa39e5cde6b64ccf3d1335cee4d4744d4ce242
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Nov 23 23:42:49 2022 +0100
build: Use «yes» instead of «true» for AC_CHECK_FUNCS cache value
This autoconf macro sets the ac_cv_func_ cached variable to «yes» not
«true» so we were checking for an impossible condition.
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 084911ce875f444a5739fae6255770b6a575aba4
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Oct 6 04:07:52 2022 +0200
Release libbsd 0.11.7
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 3538d38fe7062c35d4f405fee2ce40588c0d8205
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Oct 6 03:59:33 2022 +0200
man: Discourage using the library in non-overlay mode
This makes code using it non-portable, and requires the namespeced
headers from libbsd, instead of any generic system headers. It also
requires more code changes than the overlay mode.
man/libbsd.7 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 03fccd150512ad22c9e27e5d597bf02190ee93cf
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Oct 5 12:08:31 2022 +0200
include: Adjust reallocarray() per glibc adoption
On glibc 2.29 reallocarray() was moved to _DEFAULT_SOURCE.
Closes: !20
Based-on-patch-by: Callum Farmer <gmbr3@opensuse.org>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
include/bsd/stdlib.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
commit 6b6e686b23214ef37c30d5e1568156ba18e76f29
Author: Callum Farmer <gmbr3@opensuse.org>
Date: Wed Oct 5 12:08:31 2022 +0200
include: Adjust arc4random() per glibc adoption
Some arc4random functions were added in glibc 2.36.
Signed-off-by: Callum Farmer <gmbr3@opensuse.org>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
include/bsd/stdlib.h | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
commit da1f45ac71ac0db7f2ad48fd3dbf24e719723ee1
Author: Callum Farmer <gmbr3@opensuse.org>
Date: Mon Oct 3 16:09:18 2022 +0100
include: explicit_bzero() requires _DEFAULT_SOURCE
Signed-off-by: Callum Farmer <gmbr3@opensuse.org>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
include/bsd/string.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 2f9eddc277187e25167331ae3bde4a491fd87fa2
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Oct 5 02:05:46 2022 +0200
include: Simplify glibc version dependent macro handling
We test once whether __GLIBC__ is not defined, so we do not need to test
whether it is on the OR branch afterwards. We decouple the glibc version
restriction check from the _*_SOURCE variable, as that contains an
implicit opposite version check.
include/bsd/stdlib.h | 3 ++-
include/bsd/string.h | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
commit 28298ac0372f320174eb591e0e2879abcc568521
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Oct 5 01:35:08 2022 +0200
doc: Switch references from pkg-config to pkgconf
The former used to be the reference implementation, but it has been
stagnant to the point of not showing much signs of life. Switch to
the currently active and more complete implementation for references.
man/libbsd.7 | 6 +++---
man/setproctitle.3bsd | 2 +-
src/setproctitle_ctor.c | 2 +-
3 files changed, 5 insertions(+), 5 deletions(-)
commit ef981f930b0e7ab64eef1985d5e812bada3a6332
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Oct 4 04:28:05 2022 +0200
doc: Add missing empty line to separate README sections
README | 3 +++
1 file changed, 3 insertions(+)
commit 6928d7895edfe8a62d3c73d8938713c5ddb29774
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Oct 4 04:27:44 2022 +0200
doc: Refer to the main git repository as primary
README | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit d5865759f8698f1c75339451a26fa3ae00276a51
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Aug 25 00:52:43 2022 +0200
test: Fix explicit_bzero() test on the Hurd
On the Hurd a small read(3) might end up (indirectly) copying the data
on the stack, which we will end up finding even when we have cleared
the buffer.
To avoid these side effects, we add a new function, that we force not
to be inlined, so that we can reuse the same stack space, that will
blank any possible stack side effects. This should be portable
regardless of stack growing up or down.
Diagnosis-by: Samuel Thibault <sthibault@debian.org>
COPYING | 2 +-
test/explicit_bzero.c | 15 +++++++++++++++
2 files changed, 16 insertions(+), 1 deletion(-)
commit be327c6ebe408ae144e9c93aab9cb65fce116f33
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Aug 24 01:58:58 2022 +0200
fgetwln: Add comment about lack of getwline(3) for recommendation
Ideally we'd recommend getwline(3), but unfortunately even though it
was part of the ISO/IEC TR 24731-2:2010 draft, it did not make it into
C11 and is not widely implemented.
src/fgetwln.c | 3 +++
1 file changed, 3 insertions(+)
commit a14612d96819d5e0561bff2da89a6fdea990223c
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Aug 23 23:49:34 2022 +0200
setmode: Dot not use saveset after free
While we are only doing a pointer difference and not dereferencing it,
it's easier and more correct to do the pointer difference before passing
it to reallocarray().
Warned-by: gcc
src/setmode.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
commit f4baceb82c1de18eed363930632284455ddfec4b
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Aug 3 03:05:52 2022 +0200
man: Rewrite gerprogname(3bsd) from scratch
This gets rid of one of the last man pages with a BSD-4-clause license.
COPYING | 33 ----------------
man/getprogname.3bsd | 104 ++++++++++++++++++++++-----------------------------
2 files changed, 44 insertions(+), 93 deletions(-)
commit f35c5458477ba5c60b00ab1f4b5199296fae3826
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Aug 3 02:21:16 2022 +0200
man: Lowercase man page title
While using fully uppercase man page titles has been the usual
convention for a very long time, it is rather ugly and something that
some other projects are switching away from.
man/arc4random.3bsd | 2 +-
man/bitstring.3bsd | 2 +-
man/byteorder.3bsd | 2 +-
man/closefrom.3bsd | 2 +-
man/errc.3bsd | 2 +-
man/expand_number.3bsd | 2 +-
man/explicit_bzero.3bsd | 2 +-
man/fgetln.3bsd | 2 +-
man/fgetwln.3bsd | 2 +-
man/flopen.3bsd | 2 +-
man/fmtcheck.3bsd | 2 +-
man/fparseln.3bsd | 2 +-
man/fpurge.3bsd | 2 +-
man/funopen.3bsd | 2 +-
man/getbsize.3bsd | 2 +-
man/getpeereid.3bsd | 2 +-
man/getprogname.3bsd | 2 +-
man/heapsort.3bsd | 2 +-
man/humanize_number.3bsd | 2 +-
man/libbsd.7 | 2 +-
man/nlist.3bsd | 2 +-
man/pidfile.3bsd | 2 +-
man/pwcache.3bsd | 2 +-
man/queue.3bsd | 2 +-
man/radixsort.3bsd | 2 +-
man/readpassphrase.3bsd | 2 +-
man/reallocarray.3bsd | 2 +-
man/reallocf.3bsd | 2 +-
man/setmode.3bsd | 2 +-
man/setproctitle.3bsd | 2 +-
man/stringlist.3bsd | 2 +-
man/strlcpy.3bsd | 2 +-
man/strmode.3bsd | 2 +-
man/strnstr.3bsd | 2 +-
man/strtoi.3bsd | 2 +-
man/strtonum.3bsd | 2 +-
man/strtou.3bsd | 2 +-
man/timeradd.3bsd | 2 +-
man/timeval.3bsd | 2 +-
man/tree.3bsd | 2 +-
man/unvis.3bsd | 2 +-
man/vis.3bsd | 2 +-
man/wcslcpy.3bsd | 2 +-
43 files changed, 43 insertions(+), 43 deletions(-)
commit b466b14afb7645d06823982e7695f63cfa1e075c
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Aug 3 01:23:09 2022 +0200
man: Document that some arc4random(3) functions are now in glibc 2.36
man/libbsd.7 | 13 ++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)
commit 1f6a48b209d9d494070bb1446b6b5c49bfaa31ba
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Aug 3 02:03:05 2022 +0200
Sync arc4random(3) implementation from OpenBSD
Closes: #12
man/arc4random.3bsd | 6 +++---
src/arc4random.c | 14 ++++++++++----
src/chacha_private.h | 4 ++--
3 files changed, 15 insertions(+), 9 deletions(-)
commit 873639ebb5bc3688e5e78d71e5c0c49469498f46
Author: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Date: Tue Jun 7 19:27:13 2022 +0200
Fix ELF support for big endian SH
Fix the following build failure with big endian SH (e.g. sh4aeb):
,---
In file included from nlist.c:44:
nlist.c: In function '__elf_is_okay__':
local-elf.h:223:25: error: 'ELFDATA2LMSB' undeclared (first use in this function); did you mean 'ELFDATA2LSB'?
223 | #define ELF_TARG_DATA ELFDATA2LMSB
| ^~~~~~~~~~~~
`---
Fixes: http://autobuild.buildroot.org/results/2980fb79c208454195d77383f1ece9afbd7f981b
Closes: !19
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-elf.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit c9c78fdfd0f8551dceec4f26a007ae14bec0e5b7
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Apr 4 11:49:52 2022 +0200
man: Use -compact also for alternative functions in libbsd(7)
The other function lists use the compact mode, let's be uniform about
this.
man/libbsd.7 | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
commit 5f21307570dff129c2e982a3ab8640d09302b2bf
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Mar 31 20:46:56 2022 +0200
getentropy: Fix function cast for getauxval()
Fix also the Hurd implementation, missed in the original fix.
Extends: commit 72a82ee262795c9162e712885381a111fcf988bc
Warned-by: gcc
src/getentropy_hurd.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
commit 84acf21568e32488a73bf20d5d2ccce643a2d18f
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Mar 30 23:09:35 2022 +0200
Release libbsd 0.11.6
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 15200ec7ac97e3f169b6c2f378f0ec2f94663c9f
Author: WANG Xuerui <git@xen0n.name>
Date: Sat Sep 11 12:54:28 2021 +0800
Add LoongArch support to nlist()
Closes: !13
Signed-off-by: WANG Xuerui <git@xen0n.name>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-elf.h | 10 ++++++++++
1 file changed, 10 insertions(+)
commit f7465b93ec9fcb473df04e997067476ed2e7fd14
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Mar 30 22:56:43 2022 +0200
man: Document when functions were added to musl in libbsd(7)
The explicit_bzero(3) and reallocarray(3) functions are also present on
musl libc, mention it in the superseded section.
COPYING | 2 +-
man/libbsd.7 | 12 ++++++++----
2 files changed, 9 insertions(+), 5 deletions(-)
commit e5ed5fdd62aeec980dfeb596b191f7deeb364030
Author: Guilherme Janczak <guilherme.janczak@yandex.com>
Date: Fri Dec 31 08:25:08 2021 +0000
Remove arc4random() OpenBSD support
The arc4random() support for OpenBSD does not build. The intention was
to include any portability code so that the library could be easily
ported to such systems, but it makes little sense to build it on OpenBSD
where most of the functionality will be already present, or the software
would have been ported anyway.
[guillem@hadrons.org: Reword commit message to add rationale. ]
Closes: !15
Signed-off-by: Guillem Jover <guillem@hadrons.org>
COPYING | 1 -
src/Makefile.am | 1 -
src/arc4random.h | 4 +---
src/arc4random_openbsd.h | 61 ------------------------------------------------
4 files changed, 1 insertion(+), 66 deletions(-)
commit abb1a6b1a74cb6ae8cf4ef2a27fea34c2cd0e4f5
Author: Duncan Overbruck <mail@duncano.de>
Date: Mon Jan 24 15:11:38 2022 +0100
build: Add alpine to CI for tests with musl libc
Closes: !18
Signed-off-by: Guillem Jover <guillem@hadrons.org>
.gitlab-ci.yml | 40 +++++++++++++++++++++++++++++-----------
1 file changed, 29 insertions(+), 11 deletions(-)
commit c9ff83687c3d100551d8cff967eb1541b187333d
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jan 29 14:48:22 2022 +0100
test: Import explicit_bzero and strtonum test cases from OpenBSD
- Remove trailing spaces.
- Declare file-scope functions and variables static.
- Declare functions with a proper prototype.
- Do not mix declarations and code for C90 conformance.
- Do not compare size_t and ssize_t variables.
COPYING | 4 +
test/.gitignore | 2 +
test/Makefile.am | 2 +
test/explicit_bzero.c | 214 ++++++++++++++++++++++++++++++++++++++++++++++++++
test/strtonum.c | 64 +++++++++++++++
5 files changed, 286 insertions(+)
commit 62e67bb49e569d5b5116400c1f970349acc244b3
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jan 29 14:52:08 2022 +0100
build: Sort test programs in .gitignore
test/.gitignore | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 87b13070409f54360a7e658a425770265075f25e
Author: Duncan Overbruck <mail@duncano.de>
Date: Tue Jan 25 20:34:39 2022 +0100
test: Add fpurge() test case using open_memstream(3) FILE
Signed-off-by: Guillem Jover <guillem@hadrons.org>
test/fpurge.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
commit ba3c46b30fd45c8d2df310d89fd560c55a74eb4a
Author: Duncan Overbruck <mail@duncano.de>
Date: Tue Jan 25 20:32:30 2022 +0100
fpurge: Make it work with non fd based FILEs
Streams opened with for example open_memstream(3) will have no associated
file descriptor, and fileno(3) will fail.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/fpurge.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 091097e0626e5cd3ba5f83da47438c88977e88bc
Author: Duncan Overbruck <mail@duncano.de>
Date: Mon Jan 24 16:47:00 2022 +0100
test: Remove static FILE declaration from fpurge test
This does not work with libcs that do not declare the structure
in a header file, like musl. And gets in the way of supporting
non-fd based streams.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
test/fpurge.c | 4 ----
1 file changed, 4 deletions(-)
commit 5f9608c77561324cfe4b57e2767d0d8386f3d370
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jan 25 01:48:29 2022 +0100
Release libbsd 0.11.5
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit eef07993c9e88d79b59a63fb71bec03337bd9c06
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jan 25 01:41:14 2022 +0100
Revert "build: Add missing proctitle unit test program"
This reverts commit beafad2657c7a57109c28f8bad9cb028c84c7dd5.
This test was already handled later on as part of the BUILD_LIBBSD_CTOR
conditional. Adding it to the unconditional set made the build fail when
the system does not have GNU .init_array section support.
Closes: #9
Analysis-by: Duncan Overbruck <mail@duncano.de>
test/Makefile.am | 1 -
1 file changed, 1 deletion(-)
commit c6d589bc71d48e48912c401d276b3eb6da9b1d8d
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jan 23 21:07:45 2022 +0100
Document how to build from git and from a tarball release
Closes: #8
README | 32 ++++++++++++++++++++++++++++++++
1 file changed, 32 insertions(+)
commit 2975d809a016301420e7cbfdc7ea3b7d22a40969
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jan 23 18:54:33 2022 +0100
build: Check for objdump explicitly
We should not assume that something will implicitly check for this tool,
as we need it ourselves, and this is an internal implementation detail
of right now libtool.
Fixes: commit f11ab6722367f1cf62704ed3c827b9b68dcb5397
configure.ac | 1 +
1 file changed, 1 insertion(+)
commit f11ab6722367f1cf62704ed3c827b9b68dcb5397
Author: Sam James <sam@gentoo.org>
Date: Sun Jan 23 15:36:55 2022 +0000
build: Respect $(OBJDUMP)
We already search for it in `./configure` so let's respect
the result of that search.
This helps with cross-compilation and any other cases
where one might want to choose a different toolchain.
Closes: !16
Bug: https://bugs.gentoo.org/831863
Signed-off-by: Sam James <sam@gentoo.org>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 54796231c7eea5e2a404fd0e08773f68d7f2eead
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jan 22 22:41:51 2022 +0100
Release libbsd 0.11.4
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 7aed0edf73ad71e9224c4ff6c74bbeb9547f8fb6
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Dec 2 00:35:05 2021 +0100
man: Add missing comma in .Dd for tree(3)
Reported-by: Thorsten Glaser <tg@mirbsd.de>
man/tree.3bsd | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit fafcc397accedf1b8c3ef451cafa5f008bdb071d
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Nov 30 04:00:54 2021 +0100
man: Update tree(3) man page from OpenBSD
This man page has a BSD-3-clause-author license instead of the old
BSD-4-clause license.
COPYING | 2 +-
man/tree.3bsd | 391 +++++++++++++++++++++++++++++++++++-----------------------
2 files changed, 236 insertions(+), 157 deletions(-)
commit 48107fc8c4aa6dd6bff7e209003677d5ec3e49ea
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Nov 28 23:19:16 2021 +0100
build: Clarify link-time warnings
Mention the involved function instead of stating an implicit "this
function". Mention libbsd when proposing using an alternative libmd
to make the context clear.
src/fgetln.c | 2 +-
src/fgetwln.c | 2 +-
src/md5.c | 27 ++++++++++++++++++---------
3 files changed, 20 insertions(+), 11 deletions(-)
commit e7cf8c5785b14fc8fbd37bb665a5f9a4f28c7888
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Nov 28 22:44:08 2021 +0100
Switch md5 compatibility logic back to direct linking
When using the recent dlsym() based wrapper, we are not requiring any
symbol from libmd, as we resolve those dynamically at run-time. We were
ending up linking against libmd because in another part of the code we
require (depending on the architecture) the SHA512 functions for the
getentropy() local implementation. But that function might be provided
by the system libc on some systems, which means we end up not linking
against libmd at all.
To solve this we go back to the previous simpler solution of linking
directly, which had the main drawback of then making programs fail to
link when not specifying -lmd (on platforms that need it). And then
switch the .so link point from a symlink to a linker script, so that we
can inject the -lmd library as-needed. This is similar to what glibc is
doing.
Fixes: commit 31f034e3862debda8615a449b1c11c4d6920dcc7
.gitignore | 1 +
configure.ac | 11 +++-----
src/Makefile.am | 32 ++++++++++++++++++++-
src/md5.c | 85 ++++++++++++++++++--------------------------------------
test/Makefile.am | 5 ++++
5 files changed, 68 insertions(+), 66 deletions(-)
commit 25d35625ebd8e41756751cbb069dd607fc9fc49f
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Nov 28 22:40:58 2021 +0100
build: Split libmd dependency due to MD5 functions from SHA requirements
To be able to rework the md5 deprecation logic, we need to detangle when
we depend on libmd due to requiring MD5 functions, which might be
otherwise provided by libc, or when we require SHA functions for the
internal getentropy() implementation.
configure.ac | 3 ++-
src/Makefile.am | 1 +
src/libbsd-overlay.pc.in | 2 +-
src/libbsd.pc.in | 2 +-
4 files changed, 5 insertions(+), 3 deletions(-)
commit 500b3080a2fd27dcd14113235e05ca003ce23190
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Nov 28 22:34:59 2021 +0100
build: Add new libbsd_symver_weak() macro
We will use it for the reworked md5 deprecation logic.
src/local-link.h | 11 +++++++++++
1 file changed, 11 insertions(+)
commit 1eba40602175e9ee231cba7577c3eee975680dcb
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Nov 27 21:09:18 2021 +0100
test: Check that strdup() does not fail
Warned-by: gcc
test/fgetln.c | 1 +
1 file changed, 1 insertion(+)
commit 8ad7570c20d2381a5e1962d9b1b813d44c080837
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Nov 27 21:07:00 2021 +0100
getentropy: Add missing prototype for BSD variant
Warned-by: gcc
src/getentropy_bsd.c | 2 ++
1 file changed, 2 insertions(+)
commit 43a827031779650e63a5f787fc1959d146355153
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Nov 27 20:26:05 2021 +0100
nlist: Remove condition which is always true
The nlist() function is limited to handle ELF binaries of the same class
as size as the size_t of the architecture built.
In addition the SIZE_T_MAX macro is BSD specific, and was falling back
to the wrong constant on most 64-bit non-BSD systems.
Warned-by: gcc
src/nlist.c | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
commit 6a71b24b63ba403e6c49dbed2d31d9a73cab4890
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Nov 27 22:52:28 2021 +0100
build: Append __ after __attribute and __typeof keywords
Be consistent with other usages in the code base.
src/local-link.h | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
commit 7389fe8d243989f40900a4bbba4e493c8bd114f7
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Nov 27 06:54:49 2021 +0100
build: Ignore backup files
.gitignore | 1 +
1 file changed, 1 insertion(+)
commit 2716dfd0b7d570b6a6cbba8a4a7bc9e538d0520c
Author: Victor Westerhuis <victor@westerhu.is>
Date: Fri Nov 26 20:24:20 2021 +0100
test: Explicitly mark symbols as used
Because some of the symbols are not otherwise referenced, GCC would like
to remove them.
Closes: !14
Signed-off-by: Guillem Jover <guillem@hadrons.org>
test/nlist.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
commit 54f874565716766d6453ff050d78c70ea326d89a
Author: Victor Westerhuis <victor@westerhu.is>
Date: Fri Nov 26 20:01:18 2021 +0100
build: Enable .init_array support when building with LTO
Because these symbols are not otherwise referenced, GCC would like
to remove them.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
configure.ac | 2 +-
src/setproctitle_ctor.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
commit 428be9e0302915525513bb757e10103dbff60d4e
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Oct 7 23:08:42 2021 +0200
man: Fix .Nx macro usage
Its arguments are used as version numbers, so we need continue the
content on the next line.
man/libbsd.7 | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
commit c7a5d780ae58b6f7ae7d814fd5bc53cf1f58ee5f
Author: Alexander Miller <alex.miller@gmx.de>
Date: Thu Sep 30 03:39:57 2021 +0200
build: Allow building with -flto on gcc-10 and newer
Global asm statements (like .symver directives) do not work reliably
in gcc with link time optimization. Use the symver attribute introduced
with gcc-10 to set symbol versions instead, if available.
[guillem@hadrons.org:
- Simplify by using __has_attribute fallback from <sys/cdefs.h>.
- Coding style changes. ]
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-link.h | 12 ++++++++++++
1 file changed, 12 insertions(+)
commit 1808d64b772cf03bac159210f8692125c9a84606
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Mar 1 05:14:10 2021 +0100
test: Fix pipe_feed() to allow checking fprintf format strings
Warned-by: gcc -W
test/fgetln.c | 8 ++++----
test/fparseln.c | 2 +-
test/test-stream.c | 8 ++++++--
test/test-stream.h | 7 ++++++-
4 files changed, 17 insertions(+), 8 deletions(-)
commit beafad2657c7a57109c28f8bad9cb028c84c7dd5
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Mar 7 00:22:59 2021 +0100
build: Add missing proctitle unit test program
test/Makefile.am | 1 +
1 file changed, 1 insertion(+)
commit 6145b561784467bc6a483f48468ba4f6a742e2fe
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Aug 17 03:14:57 2021 +0200
test: Do not pass NULL as the first funopen() argument
Warned-by: gcc -W
test/funopen.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 731b0a773903a5e631071d6070d98563a7c3cb3e
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Aug 17 02:59:59 2021 +0200
build: Detect sed at configure time
Check whether sed is available and use the implementation matching the
requirements via the SED variable.
configure.ac | 1 +
man/Makefile.am | 2 +-
src/Makefile.am | 2 +-
3 files changed, 3 insertions(+), 2 deletions(-)
commit 50b50a4330e54b701d4a7b887deb864af26cd638
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Mar 2 05:18:04 2021 +0100
vis: Add prototypes for strnvis() and strnunvis() variants
Warned-by: gcc
src/unvis.c | 4 ++++
src/vis.c | 4 ++++
2 files changed, 8 insertions(+)
commit 25e88f6479466f2164c5dcf4a0798002e43f342e
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Mar 2 00:48:31 2021 +0100
test: Cast literal strings to (char *) on n_name assignment
The member is declared as n_name so we cannot directly assign a literal
string constant.
Warned-by: gcc
test/nlist.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
commit 04a8fb2469439ef3397062b4b1792d45bc95f469
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Mar 2 00:48:02 2021 +0100
Add missing prototypes to functions
Warned-by: gcc
src/explicit_bzero.c | 5 ++++-
src/setproctitle.c | 4 ++++
2 files changed, 8 insertions(+), 1 deletion(-)
commit 4f68a88f5519e1bbc8b339dd48882f7f8c613edf
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Feb 19 06:55:17 2021 +0100
build: Add compiler warnings support
Detect as many warnings as possible during configure and enable them
if the user did not supply any, so that any such problem can be spotted
and fixed.
.gitignore | 1 -
configure.ac | 42 +++++++++++++++++++++++++++++++++++++++---
m4/.gitignore | 2 ++
m4/libbsd-compiler.m4 | 24 ++++++++++++++++++++++++
4 files changed, 65 insertions(+), 4 deletions(-)
commit 8f59221c4f0383153a7c7b499fbd1344cd9ad0f1
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Feb 19 06:51:18 2021 +0100
nlist: Remove repeated shadowing variable declaration
Warned-by: gcc
src/nlist.c | 1 -
1 file changed, 1 deletion(-)
commit 72a82ee262795c9162e712885381a111fcf988bc
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Feb 20 22:22:54 2021 +0100
getentropy: Fix function cast for getauxval()
Warned-by: gcc
src/getentropy_linux.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
commit 3c305f2873580322823af53d9b9202b8ce658c32
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Feb 19 06:49:53 2021 +0100
test: Add proper prototypes for main() function
Warned-by: gcc
test/bzero.c | 2 +-
test/closefrom.c | 2 +-
test/endian.c | 2 +-
test/fpurge.c | 2 +-
test/md5.c | 2 +-
test/overlay.c | 2 +-
6 files changed, 6 insertions(+), 6 deletions(-)
commit 25278891d8b0c5af378ff548881cd3558426ba3d
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Feb 19 06:49:24 2021 +0100
Mark local functions as static
Warned-by: gcc
src/closefrom.c | 2 +-
test/funopen.c | 8 ++++----
test/md5.c | 2 +-
3 files changed, 6 insertions(+), 6 deletions(-)
commit e35d9141dcff06931287e392706f70c92c239e2e
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Feb 11 04:41:46 2021 +0100
Add link-time warnings to MD5 wrapper functions
Let's get the word out that these functions are deprecated and should be
switched away from.
src/md5.c | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
commit 4feda8704972a1eac88b5ba9ff7add92c25245ab
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Feb 11 04:40:48 2021 +0100
Require a semicolon for libbsd_link_warning() macro
Remove the semicolon in the macro definition to force adding one on the
call sites, to make the code look like an actual function.
src/fgetln.c | 2 +-
src/fgetwln.c | 2 +-
src/local-link.h | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
commit d563a17430845d043d667892c4457a14998dd4c3
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Feb 18 23:38:30 2021 +0100
man: Call the libbsd-ctor library by its name instead of bsd-ctor
man/libbsd.7 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 785cf9d1e97220483857dda9fe75728cd51e0d84
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Feb 18 23:38:30 2021 +0100
man: Fix pkg-config(1) references in libbsd(7) man page
man/libbsd.7 | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
commit 15bd284b29411638b9434bf7c4c4b1feae32033a
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 28 05:16:01 2021 +0100
build: Add code coverage support in the GitLab CI
.gitignore | 2 ++
.gitlab-ci.yml | 19 ++++++++++++++-----
2 files changed, 16 insertions(+), 5 deletions(-)
commit a9fc285988c010eaf1deb682c5d6335abf87ccab
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 28 05:14:54 2021 +0100
build: Use apt-get instead of apt in the GitLab CI
The former is to be used programmatically, while the latter is intended
for interactive use.
.gitlab-ci.yml | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
commit c0d86a641269cab5bd4583afce82f171a6215aa9
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 9 08:35:36 2021 +0100
build: Add a Libs.private field to overlay pkg-config file
We need to list all internal libraries there so that we can statically
link.
Fixes: commit 2374f409defb380d0c5c07f28b9c166ef8bdc742
src/libbsd-overlay.pc.in | 1 +
1 file changed, 1 insertion(+)
commit 1fb25b7dcad8f40ee8944208224ea0c625af8d82
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 9 06:14:25 2021 +0100
Release libbsd 0.11.3
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 31f034e3862debda8615a449b1c11c4d6920dcc7
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 9 05:57:37 2021 +0100
Switch libmd wrapper to use dlsym()
Switch from the previous versioned symbol implementation which required
users to also link against the message digest provider explicitly, or
they would fail to find the symbols, to an implementation that loads
the symbols from the linked library providing the functions using
dlsym(), thus preserving backwards compatibility.
configure.ac | 10 +++++--
src/md5.c | 86 ++++++++++++++++++++++++++++++++++++++------------------
test/Makefile.am | 2 --
3 files changed, 66 insertions(+), 32 deletions(-)
commit 2374f409defb380d0c5c07f28b9c166ef8bdc742
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 9 05:56:49 2021 +0100
build: Add a Libs.private field to pkg-config file
We need to list all internal libraries there so that we can statically
link.
src/libbsd.pc.in | 1 +
1 file changed, 1 insertion(+)
commit a4e0db2b9773d28e2e1601f5e6dc77b7bc2df60b
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 9 06:04:38 2021 +0100
build: Use a single variable to track libraries to link against
Using various variables means we have to keep these in sync in various
places. Just use a single variable that we can use anywhere where this
is needed.
configure.ac | 10 ++++++----
src/Makefile.am | 4 +---
2 files changed, 7 insertions(+), 7 deletions(-)
commit 43d34c9d3b2a24113d3901c3c7d229656cd4ce98
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 9 06:02:46 2021 +0100
build: Fix message digest library checks
They were not failing when not finding the SHA-2 functions and
were hardcoding -lmd regardless of what library had been found.
configure.ac | 13 ++++++++++---
1 file changed, 10 insertions(+), 3 deletions(-)
commit 1c3ff61699a6343ea4b5b6a757300581c5374d35
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 9 02:46:49 2021 +0100
Use uintptr_t and size_t instead of __-prefixed types in <sys/cdefs.h>
The __-prefixed types cannot be assumed to be defined. Use the standard
types instead.
Closes: #6
include/bsd/sys/cdefs.h | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
commit edea268ce9367e33b8981a3c581c5ecb531944e7
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Feb 8 03:59:56 2021 +0100
Release libbsd 0.11.2
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit e832b7687ed42ecf0daf7c5deefa86a1445d62fd
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Feb 8 03:45:06 2021 +0100
closefrom: Use close_range() on Linux when available
Closes: !11
Based-on-patch-by: cptpcrd <cptpcrd.git@gmail.com>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/closefrom.c | 21 ++++++++++++++++++++-
1 file changed, 20 insertions(+), 1 deletion(-)
commit c4fca5bb4fcf8509cb93db6e20314f22994c093b
Author: cptpcrd <cptpcrd.git@gmail.com>
Date: Sun Feb 7 14:22:21 2021 -0500
closefrom: Handle lowfd < 0 properly
More important if close_range() is going to be used, since casting
negative values to 'unsigned int' might hide the errors.
[guillem@hadrons.org: Minor coding style fix. ]
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/closefrom.c | 3 +++
1 file changed, 3 insertions(+)
commit a1f79978e8c60720d1b4217d3ada638ceb6593a5
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Feb 8 02:52:50 2021 +0100
closefrom: Import some changes from sudo
Take most of the changes done in sudo, but preserve the existing local
changes and refactoring.
In addition, refactor pstat implementation into closefrom_pstat(), so
that the code is easier to read, and requires no conditional
declarations.
src/closefrom.c | 93 ++++++++++++++++++++++++++++++---------------------------
1 file changed, 49 insertions(+), 44 deletions(-)
commit 467602628660326a54f7af7344d5539cf31aeea3
Author: Faidon Liambotis <paravoid@debian.org>
Date: Sun Feb 7 20:47:00 2021 +0200
Update <sys/queue.h> from FreeBSD
This brings <sys/queue.h> to the most up-to-date version from FreeBSD,
incorporating 18 commits from the past 5 years (2015-02-24 - 2021-01-25):
$ git log --oneline 9090a24aed70..8d55837dc133 sys/sys/queue.h share/man/man3/queue.3
Only minimal changes compared to the FreeBSD version have been applied
(queue.3 -> queue.3bsd, _LIBBSD_ prefix).
[guillem@hadrons.org: Remove reference to kernel mode in man page. ]
Closes: !12
Signed-off-by: Guillem Jover <guillem@hadrons.org>
include/bsd/sys/queue.h | 236 +++++++++++++++++++++++++++++++++++++-----
man/LIST_CLASS_ENTRY.3bsd | 1 +
man/LIST_CLASS_HEAD.3bsd | 1 +
man/Makefile.am | 9 ++
man/SLIST_CLASS_ENTRY.3bsd | 1 +
man/SLIST_CLASS_HEAD.3bsd | 1 +
man/SLIST_REMOVE_PREVPTR.3bsd | 1 +
man/STAILQ_CLASS_ENTRY.3bsd | 1 +
man/STAILQ_CLASS_HEAD.3bsd | 1 +
man/TAILQ_CLASS_ENTRY.3bsd | 1 +
man/TAILQ_CLASS_HEAD.3bsd | 1 +
man/queue.3bsd | 153 ++++++++++++++++++++++-----
12 files changed, 356 insertions(+), 51 deletions(-)
commit 25f9b30678b352e8275c98e118f5beacffbb94b4
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 7 23:24:51 2021 +0100
test: Improve code coverage for strnstr(3) unit tests
test/strnstr.c | 4 ++++
1 file changed, 4 insertions(+)
commit 18ebabf22306453f29ef63b1b1e7fb6c9ebb6ebf
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 7 10:56:51 2021 +0100
man: Update libbsd(7) man page with updates in 0.11.0
man/libbsd.7 | 43 +++++++++++++++++++++++++++++++++++++++++++
1 file changed, 43 insertions(+)
commit 4ab11c7f4893684811077574c9a2c233bedf964f
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 7 10:37:18 2021 +0100
build: Install libmd-dev in the gitlab CI
.gitlab-ci.yml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 766c883e30b5f254a3352a5fd3c0540be9416b90
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 7 10:35:57 2021 +0100
build: Switch gitlab CI to use a Debian buster
.gitlab-ci.yml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit a4de4d95a66188ede6ff4dd2a9c858ab9ade0ca0
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 7 02:03:59 2021 +0100
Release libbsd 0.11.1
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 233cab9d649137b14bb0caac045a75e4a7a562c4
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Feb 6 23:28:42 2021 +0100
Add support for new LIBBSD_VIS_OPENBSD selection macro
This will make it possible to explicitly select the OpenBSD vis
implementation (the current default) for code of OpenBSD origins.
include/bsd/vis.h | 5 ++++-
test/vis-openbsd.c | 5 ++---
2 files changed, 6 insertions(+), 4 deletions(-)
commit 2462cd88889a79f50017d23eaa376de67affc59c
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 7 00:23:43 2021 +0100
Release libbsd 0.11.0
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit d54ceb37ce9d7c04fa450a6638eaee31375bbde1
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 7 00:09:45 2021 +0100
Update copyright claims
COPYING | 2 +-
src/funopen.c | 2 +-
test/fgetln.c | 2 +-
test/setmode.c | 2 +-
4 files changed, 4 insertions(+), 4 deletions(-)
commit 847e682f8de452d5f0038458f06ae68ae3959b3a
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 7 00:09:30 2021 +0100
Use libmd hashing function implementations instead of embedding our own
This splits the implementation responsibilities, and reduces embedded
code copies, which was one of the driving points with this project to
start with, so it's nice to give a good example.
COPYING | 15 ---
README | 3 +
configure.ac | 11 ++
include/bsd/md5.h | 75 ++++-------
man/libbsd.7 | 5 +-
src/Makefile.am | 15 +--
src/getentropy_aix.c | 8 +-
src/getentropy_hpux.c | 8 +-
src/getentropy_hurd.c | 10 +-
src/getentropy_linux.c | 10 +-
src/getentropy_osx.c | 6 +-
src/getentropy_solaris.c | 8 +-
src/hash/.gitignore | 1 -
src/hash/helper.c | 105 ----------------
src/hash/md5.c | 248 ------------------------------------
src/hash/sha512.h | 53 --------
src/hash/sha512c.c | 318 -----------------------------------------------
src/libbsd.map | 2 +
src/md5.c | 91 ++++++++++++++
test/Makefile.am | 2 +
20 files changed, 163 insertions(+), 831 deletions(-)
commit 68f980c90d914e5fd6f7512e00dec334dbb71bed
Author: Aaron Dierking <aarond@fb.com>
Date: Thu Jul 5 14:47:47 2018 -0700
Provide a default progname on Windows
[guillem@hadrons.org:
- Remove .exe extension from default program name.
- Call reallocarray() once by switching to a «do {} while» loop.
- Minor coding style fixes. ]
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/progname.c | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
1 file changed, 71 insertions(+), 1 deletion(-)
commit 37a9b56c05339301510213c41fc507ea31cc2464
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Feb 6 23:43:12 2021 +0100
Import pwcache module from OpenBSD
COPYING | 3 +
configure.ac | 2 +-
include/Makefile.am | 2 +
test/overlay.c => include/bsd/grp.h | 38 ++--
test/overlay.c => include/bsd/pwd.h | 40 ++--
man/Makefile.am | 5 +
man/gid_from_group.3bsd | 1 +
man/group_from_gid.3bsd | 1 +
man/pwcache.3bsd | 143 ++++++++++++
man/uid_from_user.3bsd | 1 +
man/user_from_uid.3bsd | 1 +
src/Makefile.am | 1 +
src/libbsd.map | 5 +
src/pwcache.c | 437 ++++++++++++++++++++++++++++++++++++
test/.gitignore | 1 +
test/Makefile.am | 1 +
test/overlay.c | 3 +
test/{overlay.c => pwcache.c} | 36 ++-
18 files changed, 662 insertions(+), 59 deletions(-)
commit 45dd5229ea5f3c62877f5f66f80ab8e52d40a281
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 7 01:27:51 2021 +0100
man: Remove empty line in reallocarray(3bsd)
Warned-by: lintian
Fixes: commit 01f0d1ea1e71f1018a009ebd9203dd48e6d90c45
man/reallocarray.3bsd | 1 -
1 file changed, 1 deletion(-)
commit 01f0d1ea1e71f1018a009ebd9203dd48e6d90c45
Author: Faidon Liambotis <paravoid@debian.org>
Date: Thu Dec 31 12:46:03 2020 +0200
Add recallocarray() and freezero() from OpenBSD
Add recallocarray(), introduced in OpenBSD 6.1, and freezero(),
introduced in OpenBSD 6.2. The former is imported as-is from OpenBSD,
while the latter is the non-malloc-internal branch of the same code (and
also the OpenSSH portable variant).
Both of these originated in OpenBSD, but have also been implemented by
IllumOS, cf. https://www.illumos.org/issues/8546
Documentation for these functions is in malloc(3) upstream, the relevant
parts of which were previously imported in reallocarray(3bsd). Update
reallocarray(3bsd) with the changes that were introduced since, and add
the relevant bits for recallocarray() and freezero(), plus aliases.
[guillem@hadrons.org: Update copyright in COPYING. ]
Closes: !10
Signed-off-by: Guillem Jover <guillem@hadrons.org>
COPYING | 4 +-
include/bsd/stdlib.h | 2 +
man/Makefile.am | 2 +
man/freezero.3bsd | 1 +
man/reallocarray.3bsd | 256 ++++++++++++++++++++++++++++++++++++++++++-------
man/recallocarray.3bsd | 1 +
src/Makefile.am | 2 +
src/freezero.c | 30 ++++++
src/libbsd.map | 3 +
src/recallocarray.c | 80 ++++++++++++++++
10 files changed, 346 insertions(+), 35 deletions(-)
commit 9c85d828a1abdd698f8a587abe8cbbaaa80eade8
Author: Seth R Johnson <johnsonsr@ornl.gov>
Date: Thu Nov 14 07:26:41 2019 -0500
Fix ELF detection on Intel compilers
The Intel compiler does not define __amd64__ on x86_64 platforms;
instead, like other compilers, it defines __x86_64__ .
Closes: !8
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-elf.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit eac4ce0c674cf5051e3c90afda74db6718b0518d
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Sep 20 03:30:20 2020 +0200
man: Add a timespec(3bsd) alias to timeval(3bsd)
Even though man-pages project now includes man pages for system data
types, we still include these for any other system that does not have
them, to provide a self-contained project with code and documentation.
man/Makefile.am | 1 +
man/timespec.3bsd | 1 +
2 files changed, 2 insertions(+)
commit 5ecff0c9034243d5277c5f27ff2b620770ffc72a
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Sep 16 23:41:28 2020 +0200
man: Add missing LIBRARY section
man/bitstring.3bsd | 4 ++++
man/byteorder.3bsd | 4 ++++
man/queue.3bsd | 4 ++++
man/tree.3bsd | 4 ++++
4 files changed, 16 insertions(+)
commit 8c5a83d678cc438f53023346afe64fa3e09e15cc
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Sep 20 03:32:57 2020 +0200
Fix coding style
include/bsd/stdlib.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit d5b04ab19cf2273becb0b95274964c02f8b26c66
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Aug 16 22:01:42 2020 +0200
test: Fix short lived memory leaks
These are non-issues, but having a clean ASAN test suite makes it
possible to detect actual problems in the tested code.
Warned-by: gcc ASAN
test/fgetln.c | 13 +++++++++++--
test/setmode.c | 20 ++++++++++++++++----
2 files changed, 27 insertions(+), 6 deletions(-)
commit cfeafeabad1d415e55afb0bdc0c7b2244b4bac10
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Aug 16 21:58:04 2020 +0200
funopen: Fix memory leak in funopen_close() when closefn is NULL
We need to free the cookiewrap even when the closefn method is NULL.
Warned-by: gcc ASAN
src/funopen.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
commit 3d6b6ead64d0c822790fb017c1ad97676af5c3b9
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Nov 16 00:04:18 2019 +0100
build: Detect support for --version-script in ld
configure.ac | 19 +++++++++++++++++++
src/Makefile.am | 5 ++++-
2 files changed, 23 insertions(+), 1 deletion(-)
commit eb445425ff4559070328410574b135dcda4a96e3
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Aug 12 23:52:10 2019 +0200
Do not define SIZE_T_MAX if already defined
src/nlist.c | 2 ++
1 file changed, 2 insertions(+)
commit 59f6a95609203dd2f21a78afe94cf58bb89d2dad
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Aug 12 23:25:20 2019 +0200
man: Add missing doc-operating-system-NetBSD string variable
Fixes: commit 99320b9168ffb0112def1a712e8d59441d1b46d9.
man/vis.3bsd | 1 +
1 file changed, 1 insertion(+)
commit 3548c5f6bf10fd39336356233faedfea3f723592
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Aug 26 05:39:17 2019 +0200
Add missing strnvisx() to the symbols script
Fixes: commit 2d7de186e9cb19a756c0630ee85cb3f2d29b3484.
src/libbsd.map | 4 ++++
1 file changed, 4 insertions(+)
commit a11c98a6b5f57666260a5a4792404d81d59e418d
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Aug 7 18:34:09 2019 +0200
Release libbsd 0.10.0
configure.ac | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 5745ca03626cce0298196481dc25579063720e46
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Aug 6 15:49:41 2019 +0200
err: Add err(), warn(), errx() and warnx() familiy of functions
Some systems such as Windows or musl-libc based ones do not have these
BSD extensions. In addition libbsd itself is making use of the warnx()
functions, so we better provide these interfaces in case they are
missing.
include/bsd/err.h | 24 ++++++++++++++++++
src/err.c | 76 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
src/libbsd.map | 13 ++++++++++
3 files changed, 113 insertions(+)
commit 9628798d7d02e5f93b8dea02677676449a1ccd6c
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Aug 6 15:37:43 2019 +0200
err: Rewrite warnc() and errc() family functions to be standalone
Do not depend on the system vwarn() and verr() functions to implement
the *c() variants, as the system might actually lack any of the <err.h>
BSD extensions.
COPYING | 2 +-
include/bsd/err.h | 8 ++++----
src/err.c | 38 +++++++++++++++++++++++---------------
3 files changed, 28 insertions(+), 20 deletions(-)
commit f34a5f71d92f5625875f16a883790de75dd4477d
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Aug 6 15:29:54 2019 +0200
err: Mark error functions as non-returning with __dead2
include/bsd/err.h | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
commit 72c68868c87c1d31bc658b43c337e8c162d16997
Author: Michael Shigorin <mike@altlinux.org>
Date: Wed Aug 7 00:02:09 2019 +0200
Add e2k support for nlist()
This is a Russian 64-bit LE VLIW architecture named Elbrus
(formerly Elbrus 2000).
[guillem@hadrons.org:
- Place the entry in alphabetical order. ]
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-elf.h | 6 ++++++
1 file changed, 6 insertions(+)
commit a4323f2b1604c440e3049461ddab0bc0b3da447f
Author: Frank Schaefer <kelledin@gmail.com>
Date: Tue May 28 16:04:54 2019 -0500
Add AArch64 ILP32 support to nlist()
Closes: !7
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-elf.h | 4 ++++
1 file changed, 4 insertions(+)
commit 4997efa59a607a2b4aa2519a50f9e51017b667d2
Author: Rosen Penev <rosenp@gmail.com>
Date: Fri May 17 01:44:56 2019 +0000
Add ARC support to nlist()
Closes: !6
Signed-off-by: Rosen Penev <rosenp@gmail.com>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-elf.h | 6 ++++++
1 file changed, 6 insertions(+)
commit 96202c6c14e22b2cd4c02e13d419f507858cd754
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Aug 7 00:00:15 2019 +0200
Add a comment to note the ELF entries are sorted alphabetically
This should help people wanting to add new entries.
src/local-elf.h | 2 ++
1 file changed, 2 insertions(+)
commit 61d378f5e9c588ef4df40c48f367e5d2f39a9525
Author: James Clarke <jrtc27@jrtc27.com>
Date: Sun Feb 3 00:11:15 2019 +0000
Re-allow direct use of nlist.n_name in <nlist.h>
Commit e8d340de ("Remove a.out support from nlist()") introduced a copy
of the definition of nlist from a.out.h. However, as well as having
n_name inside n_un, on the various BSDs n_name could also be accessed
as a direct member of nlist, and this is made use of by FreeBSD's
usr.bin/netstat/main.c. Thus we should also add the same enclosing
anonymous union.
[guillem@hadrons.org:
- Add a minimal unit test. ]
Closes: !4
Signed-off-by: Guillem Jover <guillem@hadrons.org>
include/bsd/nlist.h | 9 ++++++---
test/nlist.c | 2 ++
2 files changed, 8 insertions(+), 3 deletions(-)
commit 9d917aad37778a9f4a96ba358415f077f3f36f3b
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Aug 7 22:58:30 2019 +0200
nlist: Fix out-of-bounds read on strtab
When doing a string comparison for a symbol name from the string table,
we should make sure we do a bounded comparison, otherwise a non-NUL
terminated string might make the code read out-of-bounds.
Warned-by: coverity
src/nlist.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
commit 18662cadfcba39607bd5f379e19cdadce5194480
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jun 15 14:33:32 2019 +0200
nlist: Fix unbounded malloc() calls
There are a couple of malloc() calls with unbounded size arguments,
coming from the parsed file. We need to make sure the size is not
larger than the file being parsed, otherwise we might end up with
out of memory conditions.
Reported-by: Daniel Hodson <daniel@elttam.com.au>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/nlist.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit ce53f7c25f64a694550886113154ce0b201be58f
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jun 15 14:33:32 2019 +0200
nlist: Fix pread() return value check
We should check for partial reads, and not continue in those cases,
as we are not retrying them, otherwise we might end up operating on
uninitialized data.
Reported-by: Daniel Hodson <daniel@elttam.com.au>
Based-on-patch-by: Daniel Hodson <daniel@elttam.com.au>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/nlist.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 24d1f4dd34cd86759673f736c16e671a6303f8a8
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jun 15 14:33:32 2019 +0200
nlist: Check whether sh_link is within bounds
The sh_link members should be >= e_shnum, otherwise we might do out of
bounds read accesses on the shdr array.
Reported-by: Daniel Hodson <daniel@elttam.com.au>
Based-on-patch-by: Daniel Hodson <daniel@elttam.com.au>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/nlist.c | 3 +++
1 file changed, 3 insertions(+)
commit e9529d9b4a7833049d34b4ec3bf018bdfe68c807
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jun 15 14:33:32 2019 +0200
nlist: Check that e_shnum and e_shentsize are within bounds
The e_shnum must not be 0, otherwise we will do a zero sized allocation
and further processing of the executable will lead to out of bounds
read/write accesses. The e_shentsize must be equal to sizeof(Elf_Shdr),
otherwise we will perform out of bounds read accesses on the shdr array.
Reported-by: Daniel Hodson <daniel@elttam.com.au>
Based-on-patch-by: Daniel Hodson <daniel@elttam.com.au>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/nlist.c | 6 ++++++
1 file changed, 6 insertions(+)
commit 3aaedb12086a77c5ea7564eb3b5b2f02f788fe61
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jun 15 14:33:32 2019 +0200
nlist: Check whether the nl argument is not NULL
This prevents programming errors.
Reported-by: Daniel Hodson <daniel@elttam.com.au>
Based-on-patch-by: Daniel Hodson <daniel@elttam.com.au>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
man/nlist.3bsd | 5 ++++-
src/nlist.c | 4 ++++
2 files changed, 8 insertions(+), 1 deletion(-)
commit 2c754f435b18a642f023278fc2372f2186a4ed8b
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 31 03:49:43 2019 +0200
man: Add man page sections to function references
Signed-off-by: Guillem Jover <guillem@hadrons.org>
man/libbsd.7 | 32 ++++++++++++++++----------------
1 file changed, 16 insertions(+), 16 deletions(-)
commit ee4d24970a637f6002ee69ca4e6622a68265e95c
Author: Sebastian <versat82@gmail.com>
Date: Sun Mar 10 10:03:12 2019 +0000
man: Fix typo
Closes: !5
Signed-off-by: Guillem Jover <guillem@hadrons.org>
man/libbsd.7 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 8d2afa3a9f5cdf40d82a81dd70994d321ef62c0e
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 31 03:49:24 2019 +0200
man: Fix typos
Signed-off-by: Guillem Jover <guillem@hadrons.org>
man/libbsd.7 | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit e9f6faf3aabda51943e0ede5fceaaf8e7c9759bb
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 31 03:02:38 2019 +0200
man: Replace references to a.out(5) with elf(5)
The a.out(5) support in nlist(3) got removed some time ago, and
there is now only elf(5) support.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
TODO | 1 -
man/nlist.3bsd | 4 ++--
2 files changed, 2 insertions(+), 3 deletions(-)
commit 99320b9168ffb0112def1a712e8d59441d1b46d9
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jun 13 23:43:57 2019 +0200
man: Define doc-operating-system-NetBSD string variables
This way we do not depend on the installed groff being new enough.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
man/errc.3bsd | 1 +
man/strtoi.3bsd | 1 +
man/strtonum.3bsd | 1 +
man/strtou.3bsd | 1 +
4 files changed, 4 insertions(+)
commit 71c710e9a83326023746e7e84091cd4964964ca6
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jun 13 23:42:49 2019 +0200
man: Use major.minor version for .Nx macros
The macro only recognizes this version form, and not just major alone.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
man/strtoi.3bsd | 2 +-
man/strtonum.3bsd | 2 +-
man/strtou.3bsd | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
commit 21f4052c5b376800c4251462e10fa4b9630c6c69
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jun 13 23:36:09 2019 +0200
man: Add doc-str-Lb-libbsd aliases for str-Lb-libbsd
groff(1) has changed the internal layout for the .Lb doc strings, but to
preserve backwards compatibility we cannot simply rename them, we need
to create new aliases so that these will work with old and new macros.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
man/arc4random.3bsd | 1 +
man/closefrom.3bsd | 1 +
man/errc.3bsd | 1 +
man/expand_number.3bsd | 1 +
man/explicit_bzero.3bsd | 1 +
man/fgetln.3bsd | 1 +
man/fgetwln.3bsd | 1 +
man/flopen.3bsd | 1 +
man/fmtcheck.3bsd | 1 +
man/fparseln.3bsd | 1 +
man/fpurge.3bsd | 1 +
man/funopen.3bsd | 1 +
man/getbsize.3bsd | 1 +
man/getpeereid.3bsd | 1 +
man/getprogname.3bsd | 1 +
man/heapsort.3bsd | 1 +
man/humanize_number.3bsd | 1 +
man/mdX.3bsd | 1 +
man/nlist.3bsd | 1 +
man/pidfile.3bsd | 1 +
man/radixsort.3bsd | 1 +
man/readpassphrase.3bsd | 1 +
man/reallocarray.3bsd | 1 +
man/reallocf.3bsd | 1 +
man/setmode.3bsd | 1 +
man/setproctitle.3bsd | 1 +
man/stringlist.3bsd | 1 +
man/strlcpy.3bsd | 1 +
man/strmode.3bsd | 1 +
man/strnstr.3bsd | 1 +
man/strtoi.3bsd | 1 +
man/strtonum.3bsd | 1 +
man/strtou.3bsd | 1 +
man/timeradd.3bsd | 1 +
man/timeval.3bsd | 1 +
man/unvis.3bsd | 1 +
man/vis.3bsd | 1 +
man/wcslcpy.3bsd | 1 +
38 files changed, 38 insertions(+)
commit 1899e2c5ab19526706bbe7386171ff0f06cfaa44
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 31 02:58:01 2019 +0200
Update TODO
Signed-off-by: Guillem Jover <guillem@hadrons.org>
TODO | 1 +
1 file changed, 1 insertion(+)
commit 480334080262a705bc029d0acb62d49900bfbe3c
Author: Aaron Dierking <aarond@fb.com>
Date: Thu Jun 14 11:38:32 2018 -0700
Provide a <sys/param.h> with MIN() and MAX()
Windows doesn't provide <sys/param.h>. Several libbsd sources require it
for MIN(), and these are useful non-system-specific macros anyway.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
COPYING | 2 ++
include/Makefile.am | 1 +
include/bsd/sys/param.h | 49 +++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 52 insertions(+)
commit f99b8ea52737701820078e9efd59fa75f348878e
Author: Aaron Dierking <aarond@fb.com>
Date: Thu Jun 14 11:38:33 2018 -0700
build: Disable CRT warnings on Windows
These warnings are not helpful for libbsd.
[guillem@hadrons.org:
- Rename WINDOWS conditional to OS_WINDOWS.
- Add a nil terminator to the AM_CPPFLAGS. ]
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/Makefile.am | 7 +++++++
1 file changed, 7 insertions(+)
commit 4bed48398ff97b2d98cf4665b528a939c620522c
Author: Aaron Dierking <aarond@fb.com>
Date: Thu Jun 14 11:38:32 2018 -0700
build: Detect Windows/MinGW at configure time
Extend the host OS checks to define an OS_WINDOWS automake conditional if
the host is MinGW-like. This will be useful for future Windows-specific
build tweaks.
[guillem@hadrons.org:
- Rename WINDOWS conditional to OS_WINDOWS. ]
Signed-off-by: Guillem Jover <guillem@hadrons.org>
configure.ac | 5 +++++
1 file changed, 5 insertions(+)
commit 2e071c3cc152ec55db7b87248fdc017a0f735302
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Aug 6 19:14:29 2019 +0200
build: Support platforms without symbol versioning
The .symver directive is ELF-specific. On non-ELF platforms, work around
this with __attribute__((__alias__)) for the default symbol, and ignore
the variant versioned symbols.
Based-on-patch-by: Aaron Dierking <aarond@fb.com>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-link.h | 7 +++++++
1 file changed, 7 insertions(+)
commit 890699a78b892a8591cd465f97d4967ee94d54c9
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Aug 6 18:51:45 2019 +0200
build: Abstract symbol versioning via new libbsd_symver_* macros
This makes it more obvious what they are doing. It will make it easier
to make these directives more portable, as they are really ELF specific.
src/local-link.h | 7 +++++++
src/setproctitle.c | 5 +++--
src/unvis.c | 6 ++++--
src/vis.c | 6 ++++--
4 files changed, 18 insertions(+), 6 deletions(-)
commit b0ebb0d4c26b281facbab7a774510b541637b13b
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Aug 6 23:16:42 2019 +0200
build: Use __register_atfork() only if really available
This is a glibc-specific symbol that has no public declaration. But is
being used by the OpenBSD and this implementation as a hack to avoid
having to link against the pthread library. This interface is at least
included in LSB 5.0 [L], and using pthread_atfork() is otherwise
problematic anyway [P].
[L] <https://refspecs.linuxfoundation.org/LSB_5.0.0/LSB-Core-generic/LSB-Core-generic/baselib---register-atfork.html>
[P] <http://austingroupbugs.net/view.php?id=851>
One problem is that we were using it whenever __GLIBC__ is defined,
which is supposed to be defined only on an actual glibc, but uClibc
defines that macro, but it does not provide the symbol on its noMMU
variant.
We add a new configure check that will try to link a program that uses
that symbol to make sure it is present.
Closes: !2
Reported-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
configure.ac | 17 +++++++++++++++++
src/Makefile.am | 4 +++-
src/arc4random_linux.h | 2 +-
src/arc4random_unix.h | 2 +-
4 files changed, 22 insertions(+), 3 deletions(-)
commit 73aea4f8083e8c35ce1123e36a9967ecd6a26c97
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Aug 6 23:11:50 2019 +0200
build: Fix check for clock_gettime() within librt
The check was always setting the libraries to link to include -lrt,
as the success case includes the builtin one. Handle the various
values.
configure.ac | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
commit 7cfa2d4530325444fa71c2bdb14e11ba9d4de0b6
Author: Aaron Dierking <aarond@fb.com>
Date: Thu Jun 14 11:38:31 2018 -0700
Correct Clang feature detection
Clang's __GNUC__ and __GNUC_MINOR__ definitions are not reliable and may
not be defined at all when targeting the MSVC ABI. Use feature-checking
macros when possible or check for __clang__.
[guillem@hadrons.org: Update for __ protected keyword change. ]
Signed-off-by: Guillem Jover <guillem@hadrons.org>
include/bsd/sys/cdefs.h | 27 +++++++++++++++++----------
src/arc4random.c | 6 +++---
2 files changed, 20 insertions(+), 13 deletions(-)
commit 574c7a1365b729343494181f36376d378b54fdea
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jun 18 00:36:44 2018 +0200
Protect C language extensions with two leading and trailing underscores
This should make their usage safer against user macros.
configure.ac | 2 +-
include/bsd/sys/cdefs.h | 10 +++++-----
src/explicit_bzero.c | 2 +-
src/local-link.h | 2 +-
src/setproctitle.c | 9 ++++++---
src/setproctitle_ctor.c | 2 +-
6 files changed, 15 insertions(+), 12 deletions(-)
commit c2d9d8408869af50fd5802542a4f032375e5e7bc
Author: Aaron Dierking <aarond@fb.com>
Date: Thu Jun 14 11:38:32 2018 -0700
Guard non-portable forwarded includes
These headers are not available on Windows. <bsd/sys/cdefs.h> ensures
that __has_include() and __has_include_next() are defined.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
include/bsd/err.h | 12 ++++++------
include/bsd/getopt.h | 6 ++++++
include/bsd/sys/endian.h | 6 ++++++
include/bsd/sys/time.h | 6 ++++++
include/bsd/unistd.h | 11 ++++++-----
5 files changed, 30 insertions(+), 11 deletions(-)
commit 2ebe6d5a025dc9762db2b1854d966639e1920e60
Author: Aaron Dierking <aarond@fb.com>
Date: Thu Jun 14 11:38:32 2018 -0700
Windows support for inet_net_pton()
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/inet_net_pton.c | 5 +++++
1 file changed, 5 insertions(+)
commit aeea1f408381007aefdd391fab6d9fdb47c69521
Author: Aaron Dierking <aarond@fb.com>
Date: Thu Jun 14 11:38:32 2018 -0700
Windows support for HASHFileChunk()
<io.h> provides the necessary file I/O functions.
[guillem@hadrons.org: Move include before <hashinc>. ]
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/hash/helper.c | 3 +++
1 file changed, 3 insertions(+)
commit 0500a1bd086d2d6fe974e7ded7ea615594f1f7b0
Author: Aaron Dierking <aarond@fb.com>
Date: Thu Jun 14 11:38:32 2018 -0700
Don't require <grp.h>
This is only used in the overlay test and Windows does not provide it.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
configure.ac | 2 +-
test/overlay.c | 2 ++
2 files changed, 3 insertions(+), 1 deletion(-)
commit 3d9c6c08ed254cfe16fc53867b1fe6f12031873c
Author: Aaron Dierking <aarond@fb.com>
Date: Thu Jun 14 11:38:32 2018 -0700
Only define S_ISTXT if S_ISVTX is defined
Windows doesn't provide S_ISVTX. Prefer not defining it rather than
defining it to something invalid.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
include/bsd/unistd.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit b9dee9f69a6e9f03418bde5638642ddc8df18f74
Author: Aaron Dierking <aarond@fb.com>
Date: Thu Jun 14 11:38:31 2018 -0700
Use CHAR_BIT instead of NBBY in strnvis()
<sys/param.h> is not available on Windows.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/vis.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
commit 81c3c3e4054f88049c4401b1d472188c75bdd5e4
Author: Aaron Dierking <aarond@fb.com>
Date: Thu Jun 14 11:38:31 2018 -0700
Replace reintroduced legacy u_* type usage in strnvis() and strnunvis()
This fixes a regression caused by 2d7de18. These types are not available
on all systems.
Fixes: commit 2d7de186e9cb19a756c0630ee85cb3f2d29b3484
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/unvis.c | 3 ++-
src/vis.c | 15 +++++++++------
2 files changed, 11 insertions(+), 7 deletions(-)
commit 5e0998fa4f0300ec99d0e30c994a500d91cb40c1
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jun 9 00:08:14 2018 +0200
Remove dead code in vis
The loop only executes while len > 0, and the trinary operator in the
function argument is checking against len >= 1 which will always be
true.
Warned-by: coverity
src/vis.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 8e2d55047cc9febe38db2b44c4942dd221f182eb
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 6 05:41:34 2018 +0200
Fix vis family of functions to not leak
The code uses an internal helper function to avoid code repetition. But
to get there, the function takes a pointer to a pointer, so that the few
functions that require returning an allocated buffer can get hold of it
this way.
The problem is that the user might pass a NULL pointer and trigger an
internal allocation even if the functions are not expected to do so.
Add a new internal helper for non-allocations, that will assert that
condition, and make any other function that requires this behavior call
this one instead.
Warned-by: coverity
src/vis.c | 39 +++++++++++++++++++++++++--------------
1 file changed, 25 insertions(+), 14 deletions(-)
commit 13c32916b4baab58d93940d57fea9ff0777f1931
Author: Baruch Siach <baruch@tkos.co.il>
Date: Tue Jun 5 19:21:46 2018 +0300
flopen: Add missing <fcntl.h> include
Commit 993828d84ee (Add flopenat() function from FreeBSD) dropped the
fcntl.h header. This breaks the build with musl libc:
flopen.c: In function ‘vflopenat’:
flopen.c:60:14: error: ‘O_CREAT’ undeclared (first use in this function)
if (flags & O_CREAT) {
^~~~~~~
Restore the fcntl.h header include to fix the build.
Fixes: commit 993828d84eed0468c6c15b2818e534e6b134b8e4
Submitted-also-by: parazyd <parazyd@dyne.org>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/flopen.c | 1 +
1 file changed, 1 insertion(+)
commit 8e834cd0686794ce7f70cb915ddd754e1d1ce726
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu May 31 03:59:49 2018 +0200
build: Simplify gitlab CI configuration
Merge all stages so that we do not need to pass artifacts around.
Quiesce «apt install».
.gitlab-ci.yml | 25 ++++++-------------------
1 file changed, 6 insertions(+), 19 deletions(-)
commit e354f9b1d07b45411fc4f1b3818a5769aad4d1fa
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu May 31 03:46:14 2018 +0200
build: Install git in gitlab CI configuration
.gitlab-ci.yml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 4c5e9b478e32a7140535df475b6510af8afbeec8
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu May 31 03:34:07 2018 +0200
build: Fix gitlab CI configuration
Run «apt install» in non-interactive mode, and do not install
Recommends. Replace build-essential, which is rather fat, with gcc
and make. Execute autogen instead of autoreconf directly.
.gitlab-ci.yml | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 005b509061dcc5d6cf9495b707be81046c1cb2c8
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu May 31 01:45:28 2018 +0200
build: Add a gitlab CI configuration file
.gitlab-ci.yml | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
commit a8531ad0513074dc706929b66ad2544945d9d11a
Author: Jakub Wilk <jwilk@jwilk.net>
Date: Tue May 22 13:08:56 2018 +0200
man: Fix comma splice
Signed-off-by: Guillem Jover <guillem@hadrons.org>
man/setproctitle.3bsd | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit c4b0fd2c9f3e0f533536556c2b2e6eb6a2467ac4
Author: Jakub Wilk <jwilk@jwilk.net>
Date: Tue May 22 13:08:55 2018 +0200
man: Fix name of the function injected by libbsd-ctor
Signed-off-by: Guillem Jover <guillem@hadrons.org>
man/libbsd.7 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 1ca09c18f76a0ed2ef6349463c25d509a55e20ff
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue May 22 16:03:59 2018 +0200
Release libbsd 0.9.1
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit e4e15ed286f7739682737ec2ca6d681dbdd00e79
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue May 22 13:50:44 2018 +0200
Fix strnvis() and strnunvis() NetBSD ABI break
The NetBSD implementations have different prototypes to the ones coming
from OpenBSD, which will break builds, and have caused segfaults at
run-time. We provide now both interfaces with different prototypes as
different version nodes allow selecting them at compile-time, defaulting
for now to the OpenBSD one to avoid build-time breakage, while emitting
a compile-time warning. Later on, in 0.10.0, we will be switching the
compile-time default to the NetBSD version.
Ref: http://gnats.netbsd.org/44977
Fixes: https://bugs.debian.org/899282
include/bsd/vis.h | 34 ++++++++++++++++++++++++++++++++--
src/libbsd.map | 8 ++++++++
src/unvis.c | 27 ++++++++++++++++++++++++++-
src/vis.c | 27 ++++++++++++++++++++++++++-
test/.gitignore | 2 ++
test/Makefile.am | 2 ++
test/vis-openbsd.c | 47 +++++++++++++++++++++++++++++++++++++++++++++++
test/vis.c | 46 ++++++++++++++++++++++++++++++++++++++++++++++
8 files changed, 189 insertions(+), 4 deletions(-)
commit bf697b900c06140a6ff6d00e22a812c46144bed1
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue May 22 15:43:48 2018 +0200
Add symbol redirection support
We need this to be able to select different version symbols at
compile-time.
include/bsd/sys/cdefs.h | 9 +++++++++
1 file changed, 9 insertions(+)
commit f1966385b3a062f1932794da7622916eb3a48115
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 21 22:41:23 2018 +0200
Fix COPYING file format
We cannot refer to a License short-name if that is not on its own
License paragraph. Split several other common License fields into
their own paragraphs to avoid this problem in the future.
COPYING | 198 +++++++++++++++++++++++++++++++++-------------------------------
1 file changed, 103 insertions(+), 95 deletions(-)
commit e007233cf0ea62bbeab30f960083006cb676f973
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 21 04:41:56 2018 +0200
Release libbsd 0.9.0
configure.ac | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 3cabf46bb089bbb5924c659941b9c8cb67ce3508
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 21 03:15:59 2018 +0200
Deprecate fgetwln()
This function has the same problems as fgetln() which is already marked
as deprecated.
man/libbsd.7 | 15 +++++++++++++--
src/fgetwln.c | 5 +++++
2 files changed, 18 insertions(+), 2 deletions(-)
commit 6eebc1f2645f0c77508b5c536bac6ed81bd2502b
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 21 03:10:12 2018 +0200
Fix typo in fgetln() linker warning
src/fgetln.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit a1730c10632b9e1e800db5e280eea576bc9052ec
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue May 15 00:55:02 2018 +0200
Add Windows support for getentropy() and arc4random()
Import from OpenBSD.
COPYING | 2 ++
src/Makefile.am | 2 ++
src/arc4random.h | 2 ++
src/arc4random_win.h | 78 ++++++++++++++++++++++++++++++++++++++++++++++++++++
src/getentropy.c | 2 ++
src/getentropy_win.c | 59 +++++++++++++++++++++++++++++++++++++++
6 files changed, 145 insertions(+)
commit 6f68c930765d95ab2644c7a1210a0a640fd9d4bf
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 21 00:22:38 2018 +0200
Switch strtonum() implementation from strtoll() to strtoi()
Import from NetBSD.
COPYING | 5 +--
man/strtonum.3bsd | 83 ++++++++++++++++++++++++++++++++----------------
src/strtonum.c | 95 ++++++++++++++++++++++++++-----------------------------
3 files changed, 103 insertions(+), 80 deletions(-)
commit e13b1a337a608c3301ccb9ea344b6f97279a818f
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 21 00:20:49 2018 +0200
Import strtoi() and strtou() functions from NetBSD
COPYING | 6 +-
include/Makefile.am | 1 +
include/bsd/inttypes.h | 49 ++++++++++
man/Makefile.am | 2 +
man/libbsd.7 | 3 +
man/strtoi.3bsd | 238 +++++++++++++++++++++++++++++++++++++++++++++++++
man/strtou.3bsd | 238 +++++++++++++++++++++++++++++++++++++++++++++++++
src/Makefile.am | 2 +
src/libbsd.map | 3 +
src/strtoi.c | 97 ++++++++++++++++++++
src/strtou.c | 97 ++++++++++++++++++++
11 files changed, 735 insertions(+), 1 deletion(-)
commit ef5faeb575c21257347643fb157c6b64f62b6ffe
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun May 20 19:20:33 2018 +0200
Update few RCS keyword contents to match BSD originals
This will slightly reduce the delta, and makes it easier to compare the
sources.
src/chacha_private.h | 2 +-
src/radixsort.c | 3 ++-
2 files changed, 3 insertions(+), 2 deletions(-)
commit 2d7de186e9cb19a756c0630ee85cb3f2d29b3484
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 21 03:09:05 2018 +0200
Update vis/unvis modules from NetBSD
COPYING | 11 +-
include/bsd/vis.h | 57 +++-
man/unvis.3bsd | 201 ++++++++-----
man/vis.3bsd | 440 +++++++++++++++++++++-------
src/libbsd.map | 12 +
src/unvis.c | 538 ++++++++++++++++++++++++----------
src/vis.c | 856 ++++++++++++++++++++++++++++++++++++++++++------------
7 files changed, 1592 insertions(+), 523 deletions(-)
commit 3efad641551f79adbacead4f1d1641e63c2efa05
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 21 01:56:33 2018 +0200
Update readpassphrase() from OpenBSD
man/readpassphrase.3bsd | 16 ++++---
src/readpassphrase.c | 116 ++++++++++++++++++++++++++----------------------
2 files changed, 73 insertions(+), 59 deletions(-)
commit a6f407ab0de24c725cb8c66a06ab30527e5c33f2
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 21 01:34:17 2018 +0200
Update heapsort() from OpenBSD
src/heapsort.c | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
commit 21edbb4f22935f2c0484db6147dfd9825adb8ec0
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 21 00:31:15 2018 +0200
Update fmtcheck() from NetBSD
man/fmtcheck.3bsd | 61 ++++++++-----------
src/fmtcheck.c | 174 +++++++++++++++++++++++++++++++++++++++---------------
2 files changed, 153 insertions(+), 82 deletions(-)
commit e3979d1a7ce2777ea959f3361573a10af90db63d
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun May 20 19:22:16 2018 +0200
Update humanize_number() from FreeBSD
Implements HN_IEC_PREFIXES.
COPYING | 1 +
include/bsd/libutil.h | 16 +++---
src/humanize_number.c | 133 ++++++++++++++++++++++++++++++++------------------
3 files changed, 95 insertions(+), 55 deletions(-)
commit facbddb652eba99c9334e4e390b9d829c590d4c2
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun May 20 19:18:18 2018 +0200
Update pidfile module from FreeBSD
Use EINVAL instead of EDOOFUS. Add a missing synopsis for
pidfile_fileno() in the man page. Move the definition of struct pidfh
from libutil.h into pidfile.c following upstream change.
include/bsd/libutil.h | 9 ++----
man/pidfile.3bsd | 77 ++++++++++++++++++++++++++++++++++++++++-----------
src/libbsd.map | 2 ++
src/pidfile.c | 58 +++++++++++++++++++++++++++-----------
4 files changed, 107 insertions(+), 39 deletions(-)
commit 3d88c999b4a0ac2820c84732262ba7a0ad44e421
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue May 15 00:41:26 2018 +0200
Update arc4random() headers from OpenBSD
Split Linux support into its own header separate from the generic Unix
to fix a Linux-specific issue with clone(). Reset rsp to NULL on failure.
COPYING | 1 +
src/Makefile.am | 3 ++-
src/arc4random.h | 2 ++
src/{arc4random_unix.h => arc4random_linux.h} | 12 ++++--------
src/arc4random_unix.h | 3 ++-
5 files changed, 11 insertions(+), 10 deletions(-)
commit e42381dc51065e6d48ae982a01888dddde26ef7b
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue May 15 00:41:26 2018 +0200
Update getentropy() code from OpenBSD
Includes changes to handle the Linux syscall blocking when there is not
enough entropy during boot, by switching it to non-blocking mode and
falling back to the alternative implementations. Man page URL reference
fixes. Build fixes for Mac OS X.
Fixes: https://bugs.debian.org/898088
src/getentropy_aix.c | 4 ++--
src/getentropy_bsd.c | 4 ++--
src/getentropy_hpux.c | 2 +-
src/getentropy_hurd.c | 4 ++--
src/getentropy_linux.c | 25 ++++++++++++++-----------
src/getentropy_osx.c | 15 +++++++++++++--
src/getentropy_solaris.c | 4 ++--
7 files changed, 36 insertions(+), 22 deletions(-)
commit 993828d84eed0468c6c15b2818e534e6b134b8e4
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 21 01:11:46 2018 +0200
Add flopenat() function from FreeBSD
COPYING | 2 +-
include/bsd/libutil.h | 1 +
man/flopen.3bsd | 42 +++++++++++++++++++++++++++-------
src/flopen.c | 62 ++++++++++++++++++++++++++++++++++++++++++---------
src/libbsd.map | 4 ++++
5 files changed, 92 insertions(+), 19 deletions(-)
commit 30b4d507540bada5533eea60a850090ccc54d397
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 21 03:00:47 2018 +0200
Add __arraycount() macro from NetBSD
include/bsd/sys/cdefs.h | 6 ++++++
1 file changed, 6 insertions(+)
commit f6ed7c278bf9cf5db89da375505f636de3009598
Author: Baruch Siach <baruch@tkos.co.il>
Date: Tue Apr 3 20:10:14 2018 +0300
Fix build for openrisc with uClibc
uClibc defines EM_OR1K instead of EM_OPENRISC for the OpenRISC ELF
e_machine ID. Use EM_OR1K when EM_OPENRISC is not defined.
This fixes the following build failure:
In file included from nlist.c:44:0:
nlist.c: In function ‘__elf_is_okay__’:
local-elf.h:224:23: error: ‘EM_OPENRISC’ undeclared (first use in this function)
#define ELF_TARG_MACH EM_OPENRISC
^
nlist.c:77:26: note: in expansion of macro ‘ELF_TARG_MACH’
if (ehdr->e_machine == ELF_TARG_MACH &&
^
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-elf.h | 4 ++++
1 file changed, 4 insertions(+)
commit 1f8a3f7bccfc84b195218ad0086ebd57049c3490
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Mar 6 01:39:45 2018 +0100
Fix function declaration protection for glibc already providing them
On non-glibc based systems we cannot unconditionally use the
__GLIBC_PREREQ macro as it gets expanded before evaluation. Instead,
if it is undefined, define it to 0.
We should also always declare these functions on non-glibc based
systems. And on systems with a new enough glibc, which provides these
functions, we should still provide the declarations if _GNU_SOURCE
is *not* defined.
Reported-by: Jörg Krause <joerg.krause@embedded.rocks>
include/bsd/stdlib.h | 3 ++-
include/bsd/string.h | 3 ++-
include/bsd/sys/cdefs.h | 8 ++++++++
3 files changed, 12 insertions(+), 2 deletions(-)
commit b20272f5a966333b49fdf2bda797e2a9f0227404
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Mar 6 01:42:52 2018 +0100
Remove <features.h> inclusion from <bsd/libutil.h>
This is a non-portable header, and we should not assume it is present.
Let the first system header pull it in if needed.
include/bsd/libutil.h | 1 -
1 file changed, 1 deletion(-)
commit 11ec8f1e5dfa1c10e0c9fb94879b6f5b96ba52dd
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Mar 6 01:41:35 2018 +0100
Handle systems missing <sys/cdefs.h>
This is a non-portable header, and we cannot expect it to be provided by
the system libc (e.g. musl). We just need and rely on declaration that
we have defined ourselves in our own <bsd/sys/cdefs.h>. So we switch to
only ever assume that.
Fixes: https://bugs.freedesktop.org/105281
include/bsd/libutil.h | 4 ++++
include/bsd/md5.h | 4 ++++
include/bsd/nlist.h | 4 ++++
include/bsd/readpassphrase.h | 4 ++++
include/bsd/stdlib.h | 4 ++++
include/bsd/string.h | 4 ++++
include/bsd/stringlist.h | 5 +++++
include/bsd/sys/queue.h | 4 ++++
include/bsd/sys/tree.h | 4 ++++
include/bsd/timeconv.h | 4 ++++
include/bsd/vis.h | 4 ++++
include/bsd/wchar.h | 4 ++++
12 files changed, 49 insertions(+)
commit 5ba8c5bab05c8315439c351e91ce554d4f092915
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Mar 5 00:37:47 2018 +0100
progname: Port to Windows
Define the directory separator depending on the system targetted.
Reported-by: Progyan Bhattacharya <progyanb@acm.org>
src/progname.c | 20 ++++++++++++++------
1 file changed, 14 insertions(+), 6 deletions(-)
commit 0093ca2b0e3fcbb71649682a84def684340f01c9
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Mar 5 00:02:34 2018 +0100
Handle SPARC V8+ on Sun Studio compiler
src/local-elf.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 0b65d43963fc1bea195e94e3af922a7893bf6fcd
Author: James Clarke <jrtc27@jrtc27.com>
Date: Sun Mar 4 23:44:52 2018 +0100
Add support for ELF machine EM_SPARC32PLUS
32-bit SPARC on V8+ uses a different ELF machine type.
Fixes: https://bugs.gentoo.org/634550
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-elf.h | 4 ++++
1 file changed, 4 insertions(+)
commit 0b61c5ffeda8fc094e6aabc70d4d99058e46d769
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jan 13 16:20:35 2018 +0100
Release libbsd 0.8.7
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 9ceac74e91411d3f7dbbc42d772f3500c47c7cec
Author: Jason Duerstock <jason.duerstock@gmail.com>
Date: Sun Dec 3 16:50:07 2017 +0100
test: Fix nlist(3) unit test on IA64
On IA64 this is only the case in the ELF binary, but it gets normalized
when loaded at run-time.
Fixes: https://bugs.debian.org/881611
Signed-off-by: Guillem Jover <guillem@hadrons.org>
test/nlist.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 9afc7100a1078e177ff68349446526efe6872618
Author: Adam Lackorzynski <adam@os.inf.tu-dresden.de>
Date: Sun Dec 3 16:46:19 2017 +0100
Fix <sys/cdefs.h> for gcc with no __has_include or __has_include_next support
Fixes: https://bugs.freedesktop.org/103396
Signed-off-by: Guillem Jover <guillem@hadrons.org>
include/bsd/sys/cdefs.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 22fbd62368c39de8ac5e249d1502d5ac0ffdef30
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Sep 2 19:55:50 2017 +0200
Handle several functions now being provided by glibc
We mention that these are now superseded by the glibc implementations,
make the headers cope with already declared functions on glibc-based
systems, and document this in the man pages.
include/bsd/stdlib.h | 2 ++
include/bsd/string.h | 2 ++
man/explicit_bzero.3bsd | 3 ++-
man/libbsd.7 | 33 ++++++++++++++++++++++++++++-----
man/reallocarray.3bsd | 3 ++-
5 files changed, 36 insertions(+), 7 deletions(-)
commit b4f7c065ba6d6649c33f8876445ed30b971fe09e
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Aug 5 13:42:56 2017 +0200
man: Document on what other BSDs arc4random(3) is present
man/arc4random.3bsd | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
commit bbf90ac3cd55ee5b19b18bc445a066114d6ddfa4
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jul 17 01:01:13 2017 +0200
Release libbsd 0.8.6
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 2a8514d8a5708c2c42c5b1f9fd20bb88e71ef880
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jul 17 00:57:07 2017 +0200
Fix handling of non-contiguous argv + envp in setproctitle()
The two arrays might not reference contiguous memory, and assuming they
are does break at least now on GNU/Hurd, which contains an unmapped
memory block between the memory used by the two arrays.
Just check that each element is strictly after the previous one, so that
we know there are no unmapped memory blocks inbetween.
src/setproctitle.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 3b2b7938f7b6ddb2ff042b974e30311893113f3a
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jun 25 01:51:30 2017 +0200
test: Fix nlist() unit test on IA64 and PowerPC 64-bit ELFv1
At least on IA64 and PowerPC 64-bit ELFv1, the functions are stored in
the .text sections but they are accessed through a function descriptor
stored in a data section, for example for PowerPC 64-bit ELFv1 that
section is called .opd.
We should take this into account when checking the n_type for the
functions we have requested information from nlist().
Rationale-by: James Clarke <jrtc27@jrtc27.com>
test/nlist.c | 9 +++++++++
1 file changed, 9 insertions(+)
commit 415e3cb266b66683adf545f76d8844e74b9658f6
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jun 24 16:10:14 2017 +0200
Release libbsd 0.8.5
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 9532cb39f4cf47c9a93633d8001b3a77af05ade8
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 23 05:59:35 2017 +0200
man: Update man page sections in titles and references
We have moved all man pages to section 3bsd, let's do the same for the
page title, and in all the references for uniformity and to avoid
confusions.
Fixes: https://bugs.freedesktop.org/101545
man/arc4random.3bsd | 2 +-
man/bitstring.3bsd | 2 +-
man/byteorder.3bsd | 2 +-
man/closefrom.3bsd | 2 +-
man/errc.3bsd | 2 +-
man/expand_number.3bsd | 2 +-
man/explicit_bzero.3bsd | 2 +-
man/fgetln.3bsd | 2 +-
man/fgetwln.3bsd | 2 +-
man/flopen.3bsd | 2 +-
man/fmtcheck.3bsd | 2 +-
man/fparseln.3bsd | 2 +-
man/fpurge.3bsd | 2 +-
man/funopen.3bsd | 2 +-
man/getbsize.3bsd | 2 +-
man/getpeereid.3bsd | 2 +-
man/getprogname.3bsd | 2 +-
man/heapsort.3bsd | 2 +-
man/humanize_number.3bsd | 2 +-
man/nlist.3bsd | 2 +-
man/pidfile.3bsd | 2 +-
man/queue.3bsd | 2 +-
man/radixsort.3bsd | 2 +-
man/readpassphrase.3bsd | 2 +-
man/reallocarray.3bsd | 2 +-
man/reallocf.3bsd | 2 +-
man/setmode.3bsd | 2 +-
man/setproctitle.3bsd | 2 +-
man/stringlist.3bsd | 2 +-
man/strlcpy.3bsd | 2 +-
man/strmode.3bsd | 2 +-
man/strnstr.3bsd | 2 +-
man/strtonum.3bsd | 2 +-
man/timeradd.3bsd | 6 +++---
man/timeval.3bsd | 4 ++--
man/tree.3bsd | 2 +-
man/unvis.3bsd | 2 +-
man/vis.3bsd | 4 ++--
man/wcslcpy.3bsd | 2 +-
39 files changed, 43 insertions(+), 43 deletions(-)
commit a4dd754c8dab4db3fc415209c91e9b77ec285d3d
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jun 22 04:58:09 2017 +0200
man: Ship and install libbsd(7)
Fixes: https://bugs.freedesktop.org/101543
man/Makefile.am | 1 +
1 file changed, 1 insertion(+)
commit b480b7a3f81cf49b9f3f0f8cdd20b33999aa7530
Author: James Cowgill <jcowgill@debian.org>
Date: Mon Jun 19 21:38:40 2017 +0200
Fix ELF definitions for MIPS in local-elf.h
Add a check for _MIPS_SIM inside the __mips__ #elif to detect mips64el
and use ELFCLASS64 in that case. Note that we can't use defined(__mips64)
here because that is also defined when the n32 ABI is in use, which uses
ELFCLASS32.
Fixes: https://bugs.debian.org/865091
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-elf.h | 4 ++++
1 file changed, 4 insertions(+)
commit 4cc20e23f5262fdeb667bbc6bd4ba57c92aac8e4
Author: James Cowgill <jcowgill@debian.org>
Date: Mon Jun 19 21:37:14 2017 +0200
Fix ELF definitions for PowerPC in local-elf.h
* ppc64el defines both __powerpc__ and __powerpc64__ but since the
__powerpc64__ #elif is below the __powerpc__ one, it will never be hit.
* Both assumed that powerpc* was big-endian.
Fixes: https://bugs.debian.org/865091
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-elf.h | 24 ++++++++++++++++++------
1 file changed, 18 insertions(+), 6 deletions(-)
commit c4e58c09508453624268f70ea1ab90850cd7411b
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jun 19 21:41:13 2017 +0200
test: Remove unused variable in nlist() unit test
test/nlist.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 736e12e8d868659095ee46d32901e034840f1454
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jun 19 21:32:01 2017 +0200
test: Handle libtool executable names in getprogname() unit test
Sometimes libtool will prefix the test programs with "lt-", we should
handle these and strip the prefix.
Fixes: https://bugs.debian.org/865090
test/progname.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
commit 8bff4b1fabde00c3ae0860b9fb83dadd7b3c6be9
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jun 19 03:16:56 2017 +0200
Release libbsd 0.8.4
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 0071b97958b48fff4fa629876f92790ab3511f7e
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jun 5 05:43:26 2017 +0200
Import <sys/time.h> for some of its macros
Fixes: https://bugs.freedesktop.org/94320
COPYING | 38 ++++++++++-
include/Makefile.am | 1 +
include/bsd/sys/time.h | 138 +++++++++++++++++++++++++++++++++++++
man/Makefile.am | 13 ++++
man/TIMESPEC_TO_TIMEVAL.3bsd | 1 +
man/TIMEVAL_TO_TIMESPEC.3bsd | 1 +
man/libbsd.7 | 3 +
man/timeradd.3bsd | 159 +++++++++++++++++++++++++++++++++++++++++++
man/timerclear.3bsd | 1 +
man/timercmp.3bsd | 1 +
man/timerisset.3bsd | 1 +
man/timersub.3bsd | 1 +
man/timespecadd.3bsd | 1 +
man/timespecclear.3bsd | 1 +
man/timespeccmp.3bsd | 1 +
man/timespecisset.3bsd | 1 +
man/timespecsub.3bsd | 1 +
man/timeval.3bsd | 133 ++++++++++++++++++++++++++++++++++++
18 files changed, 495 insertions(+), 1 deletion(-)
commit cdbb9d0555b36935aba0353caab0b97acb95614c
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jun 18 20:30:40 2017 +0200
test: Add new strnstr() unit test
test/.gitignore | 1 +
test/Makefile.am | 1 +
test/strnstr.c | 45 +++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 47 insertions(+)
commit 0365d0efdaf099dd9b1147f4e01ef1b834f48aa8
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jun 18 20:30:19 2017 +0200
test: Add new setprogname() and getprogname() unit test
test/.gitignore | 1 +
test/Makefile.am | 1 +
test/progname.c | 43 +++++++++++++++++++++++++++++++++++++++++++
3 files changed, 45 insertions(+)
commit 10b1328570b54159e6c06588aef0e47b2bb348c5
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jun 18 20:29:52 2017 +0200
test: Add new setmode() and getmode() unit test
test/.gitignore | 1 +
test/Makefile.am | 1 +
test/setmode.c | 45 +++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 47 insertions(+)
commit 922eff5c5ed8517b4d78553d497bb5290f0713fa
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 14 01:52:12 2017 +0200
test: Add new nlist() unit test
test/.gitignore | 1 +
test/Makefile.am | 1 +
test/nlist.c | 79 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 81 insertions(+)
commit 8e8834d8e599c0d36a5743f93984e3777eb6d35b
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 14 02:53:35 2017 +0200
Remove RCSID tags
These are obsolete markers, and in some cases they repeat the
information already present in the comment header.
src/expand_number.c | 2 --
src/flopen.c | 2 --
src/fmtcheck.c | 5 +++--
src/fparseln.c | 3 ---
src/hash/sha512c.c | 2 --
src/inet_net_pton.c | 7 ++-----
src/merge.c | 4 ----
src/pidfile.c | 2 --
src/radixsort.c | 7 -------
src/reallocf.c | 1 -
src/setmode.c | 8 --------
src/stringlist.c | 3 ---
src/strmode.c | 4 ----
src/strnstr.c | 4 ----
src/strtonum.c | 1 -
src/timeconv.c | 2 --
src/wcslcat.c | 8 +-------
src/wcslcpy.c | 8 +-------
18 files changed, 7 insertions(+), 66 deletions(-)
commit 7938619254db81d68805b5827df36d2c5cb6ed24
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 14 02:45:13 2017 +0200
Update .gitignore for headers generator
test/.gitignore | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
commit ec5d9a685a672f77bf3f1cd40a704619aea562b6
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 14 02:44:37 2017 +0200
Namespace header inclusion protection macros
Use LIBBSD_, and remove trailing underscores.
include/bsd/libutil.h | 6 +++---
include/bsd/md5.h | 6 +++---
include/bsd/netinet/ip_icmp.h | 4 ++--
include/bsd/readpassphrase.h | 6 +++---
include/bsd/stringlist.h | 6 +++---
include/bsd/sys/bitstring.h | 6 +++---
include/bsd/sys/queue.h | 6 +++---
include/bsd/sys/tree.h | 6 +++---
include/bsd/timeconv.h | 6 +++---
include/bsd/vis.h | 6 +++---
10 files changed, 29 insertions(+), 29 deletions(-)
commit 47013bc92a1d0f71477aa018068b0923fdaf6ccf
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 14 01:49:25 2017 +0200
Fix broken mmap() usage in nlist() by switching to pread()
The offset is not page aligned, which makes mmap() return EINVAL on
Linux. Switch to use pread() which handles unaligned offset and non-page
sized reads, and because we are already loading parts of the executable
by read() calls, so there's not much point in using mmap() anyway.
src/nlist.c | 31 ++++++++++++++++---------------
1 file changed, 16 insertions(+), 15 deletions(-)
commit e8d340de9e2ce39e340dde81ee139d5631ab0049
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jun 5 05:30:27 2017 +0200
Remove a.out support from nlist()
Some libc libraries do not have an <a.out.h> header. And a.out as an
executable format is very much obsolete on pretty much all currently
supported systems, even if they might still support loading such
objects.
Remove the a.out support to increase portability.
include/bsd/nlist.h | 63 ++++++++++++--
src/nlist.c | 247 +++++++++++-----------------------------------------
2 files changed, 109 insertions(+), 201 deletions(-)
commit 7aede6a999ef7b6bd2b82aed55896611331a8eea
Author: Igor Gnatenko <i.gnatenko.brain@gmail.com>
Date: Mon Jun 27 09:21:43 2016 +0200
Make strlcpy()/strlcat() slightly easier to read
Backport new changes from OpenBSD.
[guillem@hadrons.org:
- Update copyright years in COPYING. ]
References: https://svnweb.freebsd.org/base?view=revision&revision=281135
Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
COPYING | 2 +-
src/strlcat.c | 48 ++++++++++++++++++++++++------------------------
src/strlcpy.c | 37 ++++++++++++++++++-------------------
3 files changed, 43 insertions(+), 44 deletions(-)
commit ab5db68bae418e91ae3475721845e6282f6da860
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jun 19 03:02:32 2017 +0200
build: Add missing \ at end of line
Fixes: commit 934b7a0ccbdc60313102f153eadc2f46853a505b
man/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 5a46e4867d09b375449a145e8628edb5637b60af
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jun 18 20:30:51 2017 +0200
Update TODO
TODO | 3 +++
1 file changed, 3 insertions(+)
commit 7a75f550e83d12f80ca6346db677198f45f1d9ff
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jun 6 04:56:49 2017 +0200
Update TODO
TODO | 8 ++++++++
1 file changed, 8 insertions(+)
commit f1dd5f2e7179504bc18859f323b806a46d4a5aec
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 9 05:13:32 2017 +0200
test: Add unit test for strlcpy() and strlcat()
test/.gitignore | 1 +
test/Makefile.am | 1 +
test/strl.c | 84 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 86 insertions(+)
commit c8a1b08b74dd0682b88ce334fcc795b727014713
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 9 05:14:24 2017 +0200
build: Match any glibc and musl ABIs on the host_os AS_CASE
Reported-by: Helmut Grohne <helmut@subdivi.de>
configure.ac | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 4fec871c792bb6c01dc9a82dabf21374d59bd689
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 9 04:52:45 2017 +0200
build: Quote the arguments to AC_CONDITIONAL
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 3945693ebe9919715bc3c6c139bac35e4f989a93
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 9 04:52:45 2017 +0200
build: Move AC_TYPE_UID_T close to the other AC_TYPE_* checks
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit c253365d65c5cefeb78f20cf10b817c0f5dd910e
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 9 04:52:45 2017 +0200
build: Move configure.ac comment into actual AC_CASE
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 8248e5f7a61761ee057ca7e2c4f6ee618c43c5be
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 7 23:09:40 2017 +0200
build: Use src/strlcpy.c in AC_CONFIG_SRCDIR
The src/fgetln.c file contains a function considered obsolete, use one
that is not.
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit c74ca099160820faaf8a50c46e8f33f48f3c9a18
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 7 22:46:07 2017 +0200
man: Use .In intead of .Fd macros for includes
man/mdX.3bsd | 4 ++--
man/readpassphrase.3bsd | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
commit ba9e2a5a9cc097047517257383795a3335faea43
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jun 5 06:33:47 2017 +0200
man: Add new libbsd(7) library overview man page
COPYING | 2 +-
man/arc4random.3bsd | 5 +-
man/bitstring.3bsd | 5 +-
man/byteorder.3bsd | 3 +
man/closefrom.3bsd | 5 +-
man/errc.3bsd | 3 +
man/expand_number.3bsd | 5 +-
man/explicit_bzero.3bsd | 5 +-
man/fgetln.3bsd | 5 +-
man/fgetwln.3bsd | 5 +-
man/flopen.3bsd | 5 +-
man/fmtcheck.3bsd | 5 +-
man/fparseln.3bsd | 5 +-
man/fpurge.3bsd | 3 +
man/funopen.3bsd | 5 +-
man/getbsize.3bsd | 5 +-
man/getpeereid.3bsd | 5 +-
man/getprogname.3bsd | 5 +-
man/heapsort.3bsd | 5 +-
man/humanize_number.3bsd | 5 +-
man/libbsd.7 | 206 +++++++++++++++++++++++++++++++++++++++++++++++
man/mdX.3bsd | 5 +-
man/nlist.3bsd | 5 +-
man/pidfile.3bsd | 5 +-
man/queue.3bsd | 5 +-
man/radixsort.3bsd | 5 +-
man/readpassphrase.3bsd | 5 +-
man/reallocarray.3bsd | 5 +-
man/reallocf.3bsd | 5 +-
man/setmode.3bsd | 5 +-
man/setproctitle.3bsd | 5 +-
man/stringlist.3bsd | 5 +-
man/strlcpy.3bsd | 5 +-
man/strmode.3bsd | 5 +-
man/strnstr.3bsd | 5 +-
man/strtonum.3bsd | 5 +-
man/tree.3bsd | 5 +-
man/unvis.3bsd | 5 +-
man/vis.3bsd | 5 +-
man/wcslcpy.3bsd | 5 +-
40 files changed, 356 insertions(+), 36 deletions(-)
commit 6a5a515820052986e28c53f794ab4f54c2736cb6
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 7 05:00:34 2017 +0200
man: Add missing man pages
This adds man pages for byteorder(3), errc(3) and fpurge(3), including
all their aliases.
COPYING | 8 ++-
man/Makefile.am | 15 +++++
man/be16dec.3bsd | 1 +
man/be16enc.3bsd | 1 +
man/be32dec.3bsd | 1 +
man/be32enc.3bsd | 1 +
man/be64dec.3bsd | 1 +
man/be64enc.3bsd | 1 +
man/byteorder.3bsd | 83 +++++++++++++++++++++++++
man/errc.3bsd | 175 +++++++++++++++++++++++++++++++++++++++++++++++++++++
man/fpurge.3bsd | 79 ++++++++++++++++++++++++
man/le16dec.3bsd | 1 +
man/le16enc.3bsd | 1 +
man/le32dec.3bsd | 1 +
man/le32enc.3bsd | 1 +
man/le64dec.3bsd | 1 +
man/le64enc.3bsd | 1 +
17 files changed, 371 insertions(+), 1 deletion(-)
commit 934b7a0ccbdc60313102f153eadc2f46853a505b
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jun 5 06:32:36 2017 +0200
man: Add missing aliases
man/LIST_EMPTY.3bsd | 1 +
man/LIST_ENTRY.3bsd | 1 +
man/LIST_FIRST.3bsd | 1 +
man/LIST_FOREACH.3bsd | 1 +
man/LIST_FOREACH_FROM.3bsd | 1 +
man/LIST_FOREACH_FROM_SAFE.3bsd | 1 +
man/LIST_FOREACH_SAFE.3bsd | 1 +
man/LIST_HEAD.3bsd | 1 +
man/LIST_HEAD_INITIALIZER.3bsd | 1 +
man/LIST_INIT.3bsd | 1 +
man/LIST_INSERT_AFTER.3bsd | 1 +
man/LIST_INSERT_BEFORE.3bsd | 1 +
man/LIST_INSERT_HEAD.3bsd | 1 +
man/LIST_NEXT.3bsd | 1 +
man/LIST_PREV.3bsd | 1 +
man/LIST_REMOVE.3bsd | 1 +
man/LIST_SWAP.3bsd | 1 +
man/Makefile.am | 145 ++++++++++++++++++++++++++++++-
man/RB_EMPTY.3bsd | 1 +
man/RB_ENTRY.3bsd | 1 +
man/RB_FIND.3bsd | 1 +
man/RB_FOREACH.3bsd | 1 +
man/RB_FOREACH_REVERSE.3bsd | 1 +
man/RB_GENERATE.3bsd | 1 +
man/RB_GENERATE_STATIC.3bsd | 1 +
man/RB_HEAD.3bsd | 1 +
man/RB_INIT.3bsd | 1 +
man/RB_INITIALIZER.3bsd | 1 +
man/RB_INSERT.3bsd | 1 +
man/RB_LEFT.3bsd | 1 +
man/RB_MAX.3bsd | 1 +
man/RB_MIN.3bsd | 1 +
man/RB_NEXT.3bsd | 1 +
man/RB_NFIND.3bsd | 1 +
man/RB_PARENT.3bsd | 1 +
man/RB_PREV.3bsd | 1 +
man/RB_PROTOTYPE.3bsd | 1 +
man/RB_PROTOTYPE_STATIC.3bsd | 1 +
man/RB_REMOVE.3bsd | 1 +
man/RB_RIGHT.3bsd | 1 +
man/RB_ROOT.3bsd | 1 +
man/SLIST_EMPTY.3bsd | 1 +
man/SLIST_ENTRY.3bsd | 1 +
man/SLIST_FIRST.3bsd | 1 +
man/SLIST_FOREACH.3bsd | 1 +
man/SLIST_FOREACH_FROM.3bsd | 1 +
man/SLIST_FOREACH_FROM_SAFE.3bsd | 1 +
man/SLIST_FOREACH_SAFE.3bsd | 1 +
man/SLIST_HEAD.3bsd | 1 +
man/SLIST_HEAD_INITIALIZER.3bsd | 1 +
man/SLIST_INIT.3bsd | 1 +
man/SLIST_INSERT_AFTER.3bsd | 1 +
man/SLIST_INSERT_HEAD.3bsd | 1 +
man/SLIST_NEXT.3bsd | 1 +
man/SLIST_REMOVE.3bsd | 1 +
man/SLIST_REMOVE_AFTER.3bsd | 1 +
man/SLIST_REMOVE_HEAD.3bsd | 1 +
man/SLIST_SWAP.3bsd | 1 +
man/SPLAY_EMPTY.3bsd | 1 +
man/SPLAY_ENTRY.3bsd | 1 +
man/SPLAY_FIND.3bsd | 1 +
man/SPLAY_FOREACH.3bsd | 1 +
man/SPLAY_GENERATE.3bsd | 1 +
man/SPLAY_HEAD.3bsd | 1 +
man/SPLAY_INIT.3bsd | 1 +
man/SPLAY_INITIALIZER.3bsd | 1 +
man/SPLAY_INSERT.3bsd | 1 +
man/SPLAY_LEFT.3bsd | 1 +
man/SPLAY_MAX.3bsd | 1 +
man/SPLAY_MIN.3bsd | 1 +
man/SPLAY_NEXT.3bsd | 1 +
man/SPLAY_PROTOTYPE.3bsd | 1 +
man/SPLAY_REMOVE.3bsd | 1 +
man/SPLAY_RIGHT.3bsd | 1 +
man/SPLAY_ROOT.3bsd | 1 +
man/STAILQ_CONCAT.3bsd | 1 +
man/STAILQ_EMPTY.3bsd | 1 +
man/STAILQ_ENTRY.3bsd | 1 +
man/STAILQ_FIRST.3bsd | 1 +
man/STAILQ_FOREACH.3bsd | 1 +
man/STAILQ_FOREACH_FROM.3bsd | 1 +
man/STAILQ_FOREACH_FROM_SAFE.3bsd | 1 +
man/STAILQ_FOREACH_SAFE.3bsd | 1 +
man/STAILQ_HEAD.3bsd | 1 +
man/STAILQ_HEAD_INITIALIZER.3bsd | 1 +
man/STAILQ_INIT.3bsd | 1 +
man/STAILQ_INSERT_AFTER.3bsd | 1 +
man/STAILQ_INSERT_HEAD.3bsd | 1 +
man/STAILQ_INSERT_TAIL.3bsd | 1 +
man/STAILQ_LAST.3bsd | 1 +
man/STAILQ_NEXT.3bsd | 1 +
man/STAILQ_REMOVE.3bsd | 1 +
man/STAILQ_REMOVE_AFTER.3bsd | 1 +
man/STAILQ_REMOVE_HEAD.3bsd | 1 +
man/STAILQ_SWAP.3bsd | 1 +
man/TAILQ_CONCAT.3bsd | 1 +
man/TAILQ_EMPTY.3bsd | 1 +
man/TAILQ_ENTRY.3bsd | 1 +
man/TAILQ_FIRST.3bsd | 1 +
man/TAILQ_FOREACH.3bsd | 1 +
man/TAILQ_FOREACH_FROM.3bsd | 1 +
man/TAILQ_FOREACH_FROM_SAFE.3bsd | 1 +
man/TAILQ_FOREACH_REVERSE.3bsd | 1 +
man/TAILQ_FOREACH_REVERSE_FROM.3bsd | 1 +
man/TAILQ_FOREACH_REVERSE_FROM_SAFE.3bsd | 1 +
man/TAILQ_FOREACH_REVERSE_SAFE.3bsd | 1 +
man/TAILQ_FOREACH_SAFE.3bsd | 1 +
man/TAILQ_HEAD.3bsd | 1 +
man/TAILQ_HEAD_INITIALIZER.3bsd | 1 +
man/TAILQ_INIT.3bsd | 1 +
man/TAILQ_INSERT_AFTER.3bsd | 1 +
man/TAILQ_INSERT_BEFORE.3bsd | 1 +
man/TAILQ_INSERT_HEAD.3bsd | 1 +
man/TAILQ_INSERT_TAIL.3bsd | 1 +
man/TAILQ_LAST.3bsd | 1 +
man/TAILQ_NEXT.3bsd | 1 +
man/TAILQ_PREV.3bsd | 1 +
man/TAILQ_REMOVE.3bsd | 1 +
man/TAILQ_SWAP.3bsd | 1 +
man/bit_alloc.3bsd | 1 +
man/bit_clear.3bsd | 1 +
man/bit_decl.3bsd | 1 +
man/bit_ffc.3bsd | 1 +
man/bit_ffs.3bsd | 1 +
man/bit_nclear.3bsd | 1 +
man/bit_nset.3bsd | 1 +
man/bit_set.3bsd | 1 +
man/bit_test.3bsd | 1 +
man/bitstr_size.3bsd | 1 +
man/pidfile_close.3bsd | 1 +
man/pidfile_open.3bsd | 1 +
man/pidfile_remove.3bsd | 1 +
man/pidfile_write.3bsd | 1 +
man/setproctitle_init.3bsd | 1 +
man/sl_add.3bsd | 1 +
man/sl_delete.3bsd | 1 +
man/sl_find.3bsd | 1 +
man/sl_free.3bsd | 1 +
man/sl_init.3bsd | 1 +
man/strnunvis.3bsd | 1 +
man/strnvis.3bsd | 1 +
man/strunvis.3bsd | 1 +
man/strvis.3bsd | 1 +
man/strvisx.3bsd | 1 +
144 files changed, 287 insertions(+), 1 deletion(-)
commit f20e6972b3a5ef4d1bfa2e3b2577caa3f9e357fc
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jun 5 06:43:22 2017 +0200
man: Move all man pages to section 3bsd
This should guarantee that even if the system provides or will provide
native implementations of these functions, we will not have file
conflicts.
COPYING | 64 +++++++++---------
man/.gitignore | 1 -
man/Makefile.am | 86 ++++++++++++-------------
man/{arc4random.3 => arc4random.3bsd} | 0
man/arc4random_addrandom.3 | 1 -
man/arc4random_addrandom.3bsd | 1 +
man/arc4random_buf.3 | 1 -
man/arc4random_buf.3bsd | 1 +
man/arc4random_stir.3 | 1 -
man/arc4random_stir.3bsd | 1 +
man/arc4random_uniform.3 | 1 -
man/arc4random_uniform.3bsd | 1 +
man/{bitstring.3 => bitstring.3bsd} | 0
man/{closefrom.3 => closefrom.3bsd} | 0
man/dehumanize_number.3 | 1 -
man/dehumanize_number.3bsd | 1 +
man/{expand_number.3 => expand_number.3bsd} | 2 +-
man/{explicit_bzero.3 => explicit_bzero.3bsd} | 0
man/{fgetln.3 => fgetln.3bsd} | 2 +-
man/{fgetwln.3 => fgetwln.3bsd} | 2 +-
man/{flopen.3 => flopen.3bsd} | 0
man/{fmtcheck.3 => fmtcheck.3bsd} | 0
man/{fparseln.3 => fparseln.3bsd} | 0
man/{getbsize.3 => getbsize.3bsd} | 0
man/getmode.3 | 1 -
man/getmode.3bsd | 1 +
man/{getpeereid.3 => getpeereid.3bsd} | 0
man/{getprogname.3 => getprogname.3bsd} | 2 +-
man/{heapsort.3 => heapsort.3bsd} | 2 +-
man/{humanize_number.3 => humanize_number.3bsd} | 0
man/mergesort.3 | 1 -
man/mergesort.3bsd | 1 +
man/{nlist.3 => nlist.3bsd} | 0
man/{pidfile.3 => pidfile.3bsd} | 6 +-
man/queue.3bsd | 2 +-
man/{radixsort.3 => radixsort.3bsd} | 0
man/{readpassphrase.3 => readpassphrase.3bsd} | 0
man/{reallocarray.3 => reallocarray.3bsd} | 0
man/{reallocf.3 => reallocf.3bsd} | 0
man/{setmode.3 => setmode.3bsd} | 0
man/{setproctitle.3 => setproctitle.3bsd} | 0
man/setprogname.3 | 1 -
man/setprogname.3bsd | 1 +
man/sradixsort.3 | 1 -
man/sradixsort.3bsd | 1 +
man/{stringlist.3 => stringlist.3bsd} | 0
man/strlcat.3 | 1 -
man/strlcat.3bsd | 1 +
man/{strlcpy.3 => strlcpy.3bsd} | 0
man/{strmode.3 => strmode.3bsd} | 4 +-
man/{strnstr.3 => strnstr.3bsd} | 0
man/{strtonum.3 => strtonum.3bsd} | 0
man/{tree.3 => tree.3bsd} | 2 +-
man/{unvis.3 => unvis.3bsd} | 4 +-
man/{vis.3 => vis.3bsd} | 8 +--
man/wcslcat.3 | 1 -
man/wcslcat.3bsd | 1 +
man/{wcslcpy.3 => wcslcpy.3bsd} | 6 +-
58 files changed, 107 insertions(+), 108 deletions(-)
commit 07c76b666dc8e8fd2fb4f2b716f65687b60af8c7
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jun 5 06:17:27 2017 +0200
Do not use legacy BSD u_* types
Some systems do not have these types available, and they are simply
convenience aliases. Instead use the expanded versions which are more
portable.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=101192
include/bsd/netinet/ip_icmp.h | 22 +++++++--------
include/bsd/stdlib.h | 2 +-
src/arc4random.c | 16 +++++------
src/chacha_private.h | 2 +-
src/getentropy_bsd.c | 2 +-
src/hash/helper.c | 4 +--
src/inet_net_pton.c | 8 +++---
src/merge.c | 27 +++++++++---------
src/nlist.c | 2 +-
src/radixsort.c | 64 +++++++++++++++++++++++--------------------
src/unvis.c | 7 +++--
src/vis.c | 17 +++++++-----
12 files changed, 92 insertions(+), 81 deletions(-)
commit e4475738fefe3b0c7388b293e8b0828560c6b830
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jan 20 02:20:12 2017 +0100
Try <linux/a.out.h> if <a.out.h> is not present
At least musl ships the former but not the latter.
include/bsd/nlist.h | 5 +++++
1 file changed, 5 insertions(+)
commit d6c35f618c4f3ca20a43a5a28e08cde3540e6b7c
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jan 10 04:33:15 2017 +0100
Do not provide funopen() on musl
Fixes: https://bugs.debian.org/818246
configure.ac | 6 +++++-
src/funopen.c | 10 ++++++++--
src/libbsd.map | 3 +++
3 files changed, 16 insertions(+), 3 deletions(-)
commit db7470b048a14bdc69a34fbd192ec626e1786411
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jan 10 04:27:25 2017 +0100
Gracefully handle lack of system <sys/cdefs.h>
This is the case on musl.
Fixes: https://bugs.debian.org/810589
include/bsd/sys/cdefs.h | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)
commit 368af99f554ca1c7211faf9eedfffcf45e5e76bb
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Aug 28 17:13:20 2016 +0200
Fix the __progname check to avoid the optimizer discarding the symbol
Because we were assigning to another unused variable, when building the
check with optimizations enabled, which is the default when using gcc
as the compiler, the variable was being discarded. Instead pass it to
printf() so that it cannot do so.
configure.ac | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
commit 337e62027503aa6e09ca7adbe94cd7077f3241c3
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jan 10 04:24:35 2017 +0100
Support GCC deprecated attribute for GCC older than 4.5
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=99190
Based-on-patch-by: Eric Smith <brouhaha@fedoraproject.org>
include/bsd/stdio.h | 10 +++++++---
include/bsd/sys/cdefs.h | 8 ++++++++
2 files changed, 15 insertions(+), 3 deletions(-)
commit 088f147ec8e55b760cf631a09d5defb332e7e9c7
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 8 01:49:48 2017 +0100
Add support for RISC-V
src/local-elf.h | 12 ++++++++++++
1 file changed, 12 insertions(+)
commit b2b1020d8e164d2770bf1307edca85f2d2420deb
Author: Helmut Grohne <helmut@subdivi.de>
Date: Tue Jan 10 03:47:52 2017 +0100
Add support for TileGX
Fixes: https://bugs.debian.org/847560
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-elf.h | 6 ++++++
1 file changed, 6 insertions(+)
commit 9bed430ee30e677d8774e4feba8707507979d62b
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Apr 23 10:13:23 2016 +0200
Release libbsd 0.8.3
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit cbfe0ebca92ee6dd68fa3a6c02021c10bffed7ac
Author: Szabolcs Nagy <nsz@port70.net>
Date: Sun Mar 27 12:37:09 2016 +0200
Add missing <fcntl.h> includes
These are required due to the O_* macro usage, but have passed
undetected on glibc-based systems due to implicit inclusions.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/flopen.c | 1 +
src/nlist.c | 1 +
2 files changed, 2 insertions(+)
commit f3b566bd7c56cddcc5df909828eac48e74805bcb
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Mar 27 12:31:58 2016 +0200
test: Add a unit test for md5
test/.gitignore | 1 +
test/Makefile.am | 1 +
test/md5.c | 47 +++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 49 insertions(+)
commit e86c1b5f4393f1d65fb855d16d4c056fbe39ffd4
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 14 09:00:57 2016 +0100
man: Fix ungrammatical construct
Warned-by: lintian
man/queue.3bsd | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit b7ce33cf5191b99b5edcb0cde3fa5a4950cbe451
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Feb 12 22:56:09 2016 +0100
build: Support clock_gettime() provided in librt
In older glibc versions (< 2.17) clock_gettime() is in librt. Add a
check for this to avoid build breakage for programs/libraries that
use libbsd on such systems.
Based-on-patch-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
configure.ac | 10 ++++++++++
src/Makefile.am | 2 ++
2 files changed, 12 insertions(+)
commit ed84bec5aa93030b09988c3d2e0e4d6411d0e914
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 10 10:38:51 2016 +0100
Switch URLs from http or git to https
COPYING | 2 +-
README | 13 +++++++++----
src/libbsd-ctor.pc.in | 2 +-
src/libbsd-overlay.pc.in | 2 +-
src/libbsd.pc.in | 2 +-
src/progname.c | 7 ++++---
src/setproctitle.c | 2 +-
7 files changed, 18 insertions(+), 12 deletions(-)
commit cbe305770345161f4ce5069552db71fa350dcb0c
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 7 02:53:28 2016 +0100
Fix file descriptor leak in HASHFileChunk helper
This leak only happens on error conditions, so it's not too bad.
Warned-by: coverity
src/hash/helper.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
commit 5a32ea0a72ba9fa4275080a2a51612ae50f66dd3
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Feb 7 02:47:22 2016 +0100
Fix unportable sizeof() usage
We are calculating the size of the array, and need to pass the size of
each element, not the size of a pointer to an element. Although this
happens to be the same in many cases, this is not a portable assumption.
Warned-by: coverity
src/radixsort.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 2fb148a290c1677dcf09ada4379583e244a92014
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jan 27 15:25:23 2016 +0100
Release libbsd 0.8.2
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit c8f0723d2b4520bdd6b9eb7c3e7976de726d7ff7
Author: Hanno Boeck <hanno@hboeck.de>
Date: Wed Jan 27 15:10:11 2016 +0100
Fix heap buffer overflow in fgetwln()
In the function fgetwln() there's a 4 byte heap overflow.
There is a while loop that has this check to see whether there's still
enough space in the buffer:
if (!fb->len || wused > fb->len) {
If this is true more memory gets allocated. However this test won't be
true if wused == fb->len, but at that point wused already points out
of the buffer. Some lines later there's a write to the buffer:
fb->wbuf[wused++] = wc;
This bug was found with the help of address sanitizer.
Warned-by: ASAN
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=93881
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/fgetwln.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 008316aa291e0930eba067ed7b0772d0009813b0
Author: Hanno Boeck <hanno@hboeck.de>
Date: Wed Jan 27 15:06:50 2016 +0100
test: Add missing <sys/stat.h> include
The test in test/strmode.c can fail to compile depending on the
optimization flags used.
The constants that are used in this file (S_IFREG etc.) come from the
<sys/stat.h> include file. It seems gcc ignores this error if one
compiles with "-O2" (default), but if one uses no optimization it fails.
Add the missing include and it works all the time.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=93880
Signed-off-by: Guillem Jover <guillem@hadrons.org>
test/strmode.c | 1 +
1 file changed, 1 insertion(+)
commit e4ab2c62cdc5457ea4b8cabd6c7d391810e17fc1
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jan 11 02:21:15 2016 +0100
test: Fix success return code for arc4random unit test
test/arc4random.c | 2 ++
1 file changed, 2 insertions(+)
commit bf5573f86ca0b042b3f56d4c65913d5825c82ffe
Author: Lukas Fleischer <lfleischer@lfos.de>
Date: Thu Jan 7 17:26:12 2016 +0100
test: Fix race condition in headers-*.sh
When running tests in parallel (e.g. using `make -j4 check`), the header
tests currently fail due to headers-overlay.sh and headers-system.sh
both generating headers-gen.c simultaneously, resulting in garbled
output. Fix this by using separate C files for the tests.
Signed-off-by: Lukas Fleischer <lfleischer@lfos.de>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
test/headers-overlay.sh | 6 +++---
test/headers-system.sh | 6 +++---
2 files changed, 6 insertions(+), 6 deletions(-)
commit 229f85794f9031fe724562dce7e70feedb05788d
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Dec 14 03:39:48 2015 +0100
Release libbsd 0.8.1
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 7a756875415293e4d1d4b50f1403cb1fc99a5939
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Dec 14 03:03:57 2015 +0100
Add support for GNU/Hurd to getentropy()
Reuse the getentropy code for Linux on the Hurd, which has fallbacks
for when the better interfaces are not present. And remove all the code
that is not supported currently on the Hurd. Ideally the Hurd should
get an equivalent interfaces that does not suffer from the same
problems as /dev/urandom.
COPYING | 1 +
src/Makefile.am | 1 +
src/getentropy.c | 2 +
src/getentropy_hurd.c | 446 ++++++++++++++++++++++++++++++++++++++++++++++++++
4 files changed, 450 insertions(+)
commit f84004baf22e26e835515b79613de45708a73391
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Dec 12 14:26:50 2015 +0100
test: Add new unit tests for individual headers usage
test/.gitignore | 2 +-
test/Makefile.am | 29 +++++++++++++++++++++++-----
test/headers-overlay.sh | 25 ++++++++++++++++++++++++
test/headers-system.sh | 24 +++++++++++++++++++++++
test/headers.c | 51 -------------------------------------------------
5 files changed, 74 insertions(+), 57 deletions(-)
commit cdf998a056b894a2674772d6c86f8016fec4df88
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Dec 14 00:44:47 2015 +0100
Turn <bsd/bsd.h> inert when using LIBBSD_OVERLAY
Also print a warning stating this fact.
include/bsd/bsd.h | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
commit 2c77ad593ca235e95bbc59de3b36fb9d69881529
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Dec 14 00:37:34 2015 +0100
Add missing include to <md5.h>
The header was not self-contained, it was missing definitions for some
types included in <sys/types.h>.
include/bsd/md5.h | 1 +
1 file changed, 1 insertion(+)
commit 48ac79b1883981f5135b5b9c76ca268e6cbe65b2
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Dec 12 14:27:12 2015 +0100
Use the non-overlayed libbsd headers when we need our own definitions
include/bsd/err.h | 4 ++++
include/bsd/unistd.h | 4 ++++
2 files changed, 8 insertions(+)
commit 290a1ce8f262a7f30a77c0a89eaa28876de876ed
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Dec 7 02:40:46 2015 +0100
Switch COPYING to Debian copyright machine readable format 1.0
COPYING | 1059 +++++++++++++++++++++++++++++++++------------------------------
1 file changed, 552 insertions(+), 507 deletions(-)
commit 6bcb1312f4691b92d0193e4a923a776dc6f233df
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Dec 7 02:45:52 2015 +0100
Relicense my contribution to BSD-2-clause
This avoids having two licenses on the same file.
COPYING | 2 ++
include/bsd/sys/endian.h | 52 +++++++++++++-----------------------------------
2 files changed, 16 insertions(+), 38 deletions(-)
commit da137a09213c26e5583689a8ea0bd61cdf2d6de3
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Dec 7 01:53:49 2015 +0100
Add missing copyright and license headers
src/arc4random.h | 26 ++++++++++++++++++++++++++
test/headers.c | 26 ++++++++++++++++++++++++++
test/overlay.c | 26 ++++++++++++++++++++++++++
3 files changed, 78 insertions(+)
commit d2f59a23d5e1d8bc440c061cac2a0d6fc133a79e
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Dec 2 04:00:58 2015 +0100
Fix getentropy implementation to use the correct system hooks
Include getentropy_<SYSTEM>.c instead of arc4random_<SYSTEM>.c.
src/getentropy.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
commit 01b77f0dcf7f43fe598d5f6aa34f9edfad418432
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Dec 2 03:32:13 2015 +0100
Add support for GNU/kFreeBSD for closefrom() and getentropy()
src/closefrom.c | 2 +-
src/getentropy.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
commit 75729394af82faf54721cd40c0c8c258954082dc
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Dec 2 03:08:17 2015 +0100
Unify most arc4random Unix hooks into a single file
The Unix hook should work for most Unix-like systems, move glibc
specific code there and a FreeBSd specific comment, and remove the rest.
Also change the code to always fallback to use the generic Unix code.
This should cover GNU/Hurd and GNU/kFreeBSD among others.
src/Makefile.am | 2 --
src/arc4random.h | 18 ++---------
src/arc4random_bsd.h | 86 --------------------------------------------------
src/arc4random_linux.h | 86 --------------------------------------------------
src/arc4random_unix.h | 14 +++++++-
5 files changed, 15 insertions(+), 191 deletions(-)
commit 8493c7f27da2dcd2de71e9c7782c3d020d89c2a2
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Dec 1 03:39:10 2015 +0100
Use local SHA512 header
Actually use the local private SHA512 header instead of relying on the
OpenSSL one for no good reason. Add definition for expected macro
SHA512_DIGEST_LENGTH.
src/getentropy_aix.c | 2 +-
src/getentropy_hpux.c | 3 ++-
src/getentropy_linux.c | 3 ++-
src/hash/sha512.h | 2 ++
4 files changed, 7 insertions(+), 3 deletions(-)
commit 2b030da0165ac507280a5355ba8a28c2013bf9b6
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Nov 30 03:59:42 2015 +0100
Release libbsd 0.8.0
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 330e211142e9a2ad5436ab38e3e4a8596f49cf1a
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Nov 30 03:53:21 2015 +0100
Update license and copyright information
COPYING | 23 +++++++++++++++++------
1 file changed, 17 insertions(+), 6 deletions(-)
commit 874a0e51d3a38596006b3ef7396e62194f467abf
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Sep 23 19:39:47 2015 +0200
Update arc4random module from OpenBSD and LibreSSL
Rework arc4random_stir() and arc4random_addrandom() code over the new
internal API, and documentation in the man page. Adapt the code to the
local build system.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=85827
configure.ac | 2 +-
man/arc4random.3 | 100 +++++++------
src/Makefile.am | 7 +
src/arc4random.c | 356 ++++++++++++++++++-----------------------------
src/arc4random.h | 29 ++++
src/arc4random_bsd.h | 86 ++++++++++++
src/arc4random_linux.h | 86 ++++++++++++
src/arc4random_openbsd.h | 61 ++++++++
src/arc4random_uniform.c | 57 ++++++++
src/arc4random_unix.h | 80 +++++++++++
src/chacha_private.h | 222 +++++++++++++++++++++++++++++
11 files changed, 820 insertions(+), 266 deletions(-)
commit 9a9a8b2dba2f511c0888499726597add59ae1215
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Sep 23 19:39:47 2015 +0200
Add private getentropy module from OpenBSD and LibreSSL
Adapt the code to the local build system.
configure.ac | 4 +-
src/Makefile.am | 12 ++
src/getentropy.c | 43 ++++
src/getentropy_aix.c | 425 ++++++++++++++++++++++++++++++++++++
src/getentropy_bsd.c | 62 ++++++
src/getentropy_hpux.c | 419 ++++++++++++++++++++++++++++++++++++
src/getentropy_linux.c | 547 +++++++++++++++++++++++++++++++++++++++++++++++
src/getentropy_osx.c | 429 +++++++++++++++++++++++++++++++++++++
src/getentropy_solaris.c | 445 ++++++++++++++++++++++++++++++++++++++
9 files changed, 2385 insertions(+), 1 deletion(-)
commit 5f9265f81601f591336616a4acd3bae0ece4b6fc
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Sep 23 20:13:33 2015 +0200
Add private SHA512 module from FreeBSD
src/Makefile.am | 2 +
src/hash/sha512.h | 51 +++++++++
src/hash/sha512c.c | 320 +++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 373 insertions(+)
commit 1f77cdb40a997575fed193d1edbe16af03ea733e
Author: Marek Vasut <marex@denx.de>
Date: Mon Nov 30 20:39:00 2015 +0100
Add NIOS2 support to nlist()
Add support for the NIOS2 soft-core CPU provided by Altera.
Signed-off-by: Marek Vasut <marex@denx.de>
Signed-off-by: Guillem Jover <guillem@hadrons.org>
Cc: Ley Foon Tan <lftan@altera.com>
Cc: Thomas Chou <thomas@wytron.com.tw>
Cc: Walter Goossens <waltergoossens@home.nl>
src/local-elf.h | 6 ++++++
1 file changed, 6 insertions(+)
commit f3b115540c7490c494a82e0b9c09a1dfa1c0f9b5
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Nov 30 19:32:48 2015 +0100
man: Rename funopen.3 to funopen.3bsd to avoid clash with funtools
The funtools project ships a man page with the same, name. And although
it mith probably make more sense to rename the man page there, as BSD
systems will certainly not do so, this is the easiest and fastest way
to avoid a file conflict.
man/Makefile.am | 2 +-
man/{funopen.3 => funopen.3bsd} | 0
2 files changed, 1 insertion(+), 1 deletion(-)
commit 877732ef4d101e9b6c789e9c00f88623761fc8c4
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Nov 30 23:48:17 2015 +0100
test: Check asprintf() return code
test/proctitle.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
commit 02bccb0a0135d4aac670c804824335223872f11d
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Sep 30 04:17:15 2015 +0200
test: Add unit test for strmode()
test/.gitignore | 1 +
test/Makefile.am | 1 +
test/strmode.c | 69 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 71 insertions(+)
commit 58bef83f410e8ec9201ecab671c27f56dca98f02
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Nov 16 01:12:24 2015 +0100
test: Add unit test for arc4random()
configure.ac | 5 +++
test/.gitignore | 1 +
test/Makefile.am | 6 ++++
test/arc4random.c | 105 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
4 files changed, 117 insertions(+)
commit 6e074a2bdc8377a945533d54a0013f5c7f608809
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Nov 30 23:00:35 2015 +0100
build: Make git log invocation immune to local configuration
Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 0871daf7b0031ca999d5c25f71a93a4560d7b042
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Nov 30 04:12:02 2015 +0100
build: Move hash/helper.c into new libbsd_la_included_sources
Use this variable in EXTRA_DIST and libbsd_la_DEPENDENCIES.
src/Makefile.am | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
commit 02c33d50226360de04d5a5da997a040a5413c35f
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Nov 30 02:48:23 2015 +0100
build: Move proctitle_LDFLAGS inside BUILD_LIBBSD_CTOR conditional
test/Makefile.am | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
commit 45443583df0ece8523f6b9038e305fa6c01b63f7
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Sep 23 19:37:37 2015 +0200
Add explicit_bzero() function from OpenBSD
include/bsd/string.h | 2 +
man/Makefile.am | 1 +
man/explicit_bzero.3 | 72 ++++++++++++++++++++++++++++++++++++
src/Makefile.am | 1 +
src/explicit_bzero.c | 19 ++++++++++
src/libbsd.map | 4 ++
test/.gitignore | 1 +
test/Makefile.am | 1 +
include/bsd/string.h => test/bzero.c | 33 +++++++++--------
9 files changed, 118 insertions(+), 16 deletions(-)
commit 8641d8aed711f74179915fe2fde89c9969ff7de4
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Sep 24 04:01:11 2015 +0200
Make closefrom_procfs() fail when reallocarray() fails
src/closefrom.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
commit 0982dcd98b7561269fdddaef4388da7177de7603
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Sep 23 07:10:18 2015 +0200
Lock the file streams in fgetln() and fparseln()
The fparseln() function had the NetBSD uppercase macros stubbed out,
so replace them with the actual stdio ones. The fgetln() function was
missing any locking at all.
src/fgetln.c | 5 +++++
src/fparseln.c | 8 +++-----
2 files changed, 8 insertions(+), 5 deletions(-)
commit ee26e59e727c51fcf4e01d4d4cab3b697bb6b31d
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Sep 23 05:50:52 2015 +0200
Mark functions handling format strings with __printflike
include/bsd/err.h | 12 ++++++++----
include/bsd/unistd.h | 3 ++-
2 files changed, 10 insertions(+), 5 deletions(-)
commit 151bc71d64845a1798561e66fa62ee0d62f4a03c
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Sep 22 16:22:56 2015 +0200
Add compile and link-time deprecation warnings for fgetln()
Although the current implementation in libbsd is probably one of the
safest ones around, it still poses some problems when used with many
file streams. This function has now a replacement, that is both more
standard and portable. Ask users to switch to getline(3) instead.
include/bsd/stdio.h | 7 ++++++-
src/fgetln.c | 5 +++++
test/Makefile.am | 1 +
3 files changed, 12 insertions(+), 1 deletion(-)
commit 41ff37bbccea236d67b0d54c97477741a6f13dab
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Sep 22 16:21:12 2015 +0200
build: Add support for linker warnings
src/Makefile.am | 1 +
src/local-link.h | 33 +++++++++++++++++++++++++++++++++
2 files changed, 34 insertions(+)
commit 53d989a223f4d5ab789b8813451263528536f927
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Dec 13 21:28:36 2014 +0100
Switch fparseln() implementation from fgetln() to getline()
man/fparseln.3 | 6 +++---
src/fparseln.c | 12 +++++++++---
2 files changed, 12 insertions(+), 6 deletions(-)
commit f50b197ea597e6517ffeb9666b469b227ea88387
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Sep 22 22:30:17 2015 +0200
test: Add fparseln() unit test
src/fparseln.c | 33 --------------------
test/.gitignore | 1 +
test/Makefile.am | 2 ++
test/fparseln.c | 92 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
4 files changed, 95 insertions(+), 33 deletions(-)
commit 54f153414a00b2de606f1aeaf9d76f8792e062f6
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Sep 22 20:56:15 2015 +0200
test: Refactor stream testing functions into a new module
test/Makefile.am | 2 ++
test/fgetln.c | 56 ++----------------------------------
test/test-stream.c | 84 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
test/test-stream.h | 37 ++++++++++++++++++++++++
4 files changed, 125 insertions(+), 54 deletions(-)
commit 9688ab26b921e372cc296d4d1b0d48cbcf6a96c5
Author: Brent Cook <bcook@openbsd.org>
Date: Sat Dec 13 08:55:59 2014 +0100
Avoid left shift overflow in reallocarray
Some 64-bit platforms (e.g. Windows 64) have a 32-bit long. So, shifting
1UL 32-bits to the left causes an overflow. This replaces the constant
1UL with (size_t)1 so that we get the correct constant size for the
platform.
Import from OpenBSD.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/reallocarray.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 025b44800e97f61c31b9979cc61a7b443feda05e
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Nov 4 05:34:46 2014 +0100
Make mergesort setup() static
src/merge.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit a6a101effacbdf88b5879af2f63b7e5dbc4a05b9
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Nov 4 05:33:26 2014 +0100
Use ANSI C prototypes
src/heapsort.c | 6 ++----
src/inet_net_pton.c | 11 ++---------
src/merge.c | 19 ++++++-------------
src/nlist.c | 25 ++++++-------------------
src/strmode.c | 4 +---
5 files changed, 17 insertions(+), 48 deletions(-)
commit 32388fe59f526a150058b58a8bc22785e4b6b4cc
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Nov 3 23:21:52 2014 +0100
Use reallocarray() instead of malloc() or realloc()
src/fgetwln.c | 2 +-
src/radixsort.c | 3 ++-
src/setmode.c | 5 +++--
src/stringlist.c | 6 +++---
test/fgetln.c | 4 ++--
5 files changed, 11 insertions(+), 9 deletions(-)
commit 30e328cbf14d03fc9f6569e93e0dac41526264d8
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Nov 3 00:43:27 2014 +0100
Do not close file descriptors while scanning the /proc filesystem
Closing file descriptors changes the content of the fd directories in
the /proc filesystem, which means readdir() might get very confused.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=85663
src/closefrom.c | 28 ++++++++++++++++++++++++++--
1 file changed, 26 insertions(+), 2 deletions(-)
commit 4cc43915f22c282ded2a9c3875ad7865fcb91fa5
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Nov 2 23:58:23 2014 +0100
Move procfs based implementation into a new closefrom_procfs() function
src/closefrom.c | 44 ++++++++++++++++++++++++++++----------------
1 file changed, 28 insertions(+), 16 deletions(-)
commit 34df1426653e79d170de399dfadc5b2709f85815
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Nov 5 20:01:53 2014 +0100
Refactor file descriptor closure into a new closefrom_close()
src/closefrom.c | 32 +++++++++++++++-----------------
1 file changed, 15 insertions(+), 17 deletions(-)
commit 3881c4fc68c7257ed22e1a25804039db5c9a0c95
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Nov 2 00:23:00 2014 +0100
Update closefrom() function
Import from sudo. Adapt the build system to detect the required features.
configure.ac | 5 +--
src/closefrom.c | 105 +++++++++++++++++++++++++++++++++++++-------------------
2 files changed, 72 insertions(+), 38 deletions(-)
commit 3a3d87d7301794bd4950bb583dfa590981b842e2
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Sep 23 04:40:21 2015 +0200
test: Add closefrom() unit test
test/.gitignore | 1 +
test/Makefile.am | 1 +
test/closefrom.c | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 55 insertions(+)
commit d62f7d8facf087b5e93508067ec228864fe76990
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Nov 1 00:55:55 2014 +0100
test: Add test case for fpurge(NULL)
test/fpurge.c | 3 +++
1 file changed, 3 insertions(+)
commit cfb4d462a9be19c1dfd5e7793ea267a0bb111a11
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Nov 1 00:54:09 2014 +0100
test: Move and activate fpurge() test case from module to a dedicated file
src/fpurge.c | 20 --------------------
test/.gitignore | 1 +
test/Makefile.am | 1 +
{src => test}/fpurge.c | 21 ---------------------
4 files changed, 2 insertions(+), 41 deletions(-)
commit 205827a2dd16e5a14628631eea926f9da9b672a7
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Nov 1 00:52:42 2014 +0100
build: Centralize testsuite LDADD setting in a single variable
test/Makefile.am | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
commit c7e01e9884a2478360a2629aea5583eaf7be0ea2
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Nov 1 00:22:28 2014 +0100
Sync queue(3) from FreeBSD
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=85147
include/bsd/sys/queue.h | 118 ++++++++++++++++++++++++------
man/queue.3bsd | 186 ++++++++++++++++++++++++++++++++++++++++++++++--
2 files changed, 274 insertions(+), 30 deletions(-)
commit 326711448308c4197923d75f40ae02162f152ce8
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Nov 1 00:21:30 2014 +0100
Add __offsetof, __rangeof and __containerof to sys/cdefs.h
Import and adapt from FreeBSD.
include/bsd/sys/cdefs.h | 41 +++++++++++++++++++++++++++++++++++++++++
1 file changed, 41 insertions(+)
commit 0e4e3ab2698a29a329beb5b85b9da5d425e296a6
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Nov 1 00:20:23 2014 +0100
Add __DECONST, __DEVOLATILE and __DEQUALIFY macros to sys/cdefs.h
Import from FreeBSD.
include/bsd/sys/cdefs.h | 12 ++++++++++++
1 file changed, 12 insertions(+)
commit a6fe103c1b4ff4ae8d78840ed964dc632ccd4d7c
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Oct 31 17:29:54 2014 +0100
Add new man page for reallocarray(3)
Import man page from OpenBSD.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=85622
man/Makefile.am | 1 +
man/reallocarray.3 | 102 +++++++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 103 insertions(+)
commit 02b55488c5ed1067f7b4d4139806a60919bb2e78
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Aug 12 12:32:34 2014 +0200
Use stdint integer types instead of BSD legacy ones
include/bsd/md5.h | 16 +++++++++-------
include/bsd/stdlib.h | 4 ++--
man/arc4random.3 | 6 +++---
man/mdX.3bsd | 8 ++++----
src/arc4random.c | 30 +++++++++++++++---------------
src/hash/helper.c | 2 +-
src/hash/md5.c | 20 ++++++++++----------
7 files changed, 44 insertions(+), 42 deletions(-)
commit 6378351169696f9d446de93a3efd75b4b061fecc
Author: Callum Davies <calrogman@gmail.com>
Date: Sun Aug 10 12:34:44 2014 +0100
Fix arc4random() and arc4random_stir() prototypes
These two functions accept no arguments. The prototypes should reflect
this. This change lets the compiler warn about certain (admittedly
silly) mistakes.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
include/bsd/stdlib.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit e390651b646c173ccd0648d05d3fcc4585613b01
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jul 29 03:00:08 2014 +0200
Release libbsd 0.7.0
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit e8d3d04177c8718f1e7f583cbcca15f8e0b9602e
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jul 20 01:48:20 2014 +0200
build: Remove hard requirement for GNU .init_array section support
In case the support is not available, just stop building the
libbsd-ctor.a library, which is a nice to have thing, but should not
have been a hard requirement from the start. This should allow to
build libbsd on non-glibc based systems using another libc.
configure.ac | 5 ++---
src/Makefile.am | 9 +++++++--
test/.gitignore | 1 +
test/Makefile.am | 9 ++++++++-
test/proctitle.c | 6 +++++-
5 files changed, 23 insertions(+), 7 deletions(-)
commit faa005cb3209239bdbdf001e387cbcf9f088b12c
Author: Benjamin Baier <programmer@netzbasis.de>
Date: Fri Jun 27 02:05:11 2014 +0200
Add reallocarray() function from OpenBSD
Signed-off-by: Guillem Jover <guillem@hadrons.org>
COPYING | 2 ++
include/bsd/stdlib.h | 1 +
src/Makefile.am | 1 +
src/libbsd.map | 2 ++
src/reallocarray.c | 38 ++++++++++++++++++++++++++++++++++++++
5 files changed, 44 insertions(+)
commit 36aca8c06ee6b41e917eb4f70622831852ad72f7
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jun 26 21:43:55 2014 +0200
Add stringlist module from NetBSD
COPYING | 7 ++-
include/Makefile.am | 1 +
include/bsd/stringlist.h | 54 +++++++++++++++++
man/Makefile.am | 1 +
man/stringlist.3 | 147 ++++++++++++++++++++++++++++++++++++++++++++
src/Makefile.am | 1 +
src/libbsd.map | 5 ++
src/stringlist.c | 155 +++++++++++++++++++++++++++++++++++++++++++++++
8 files changed, 370 insertions(+), 1 deletion(-)
commit e8f930035525b5bb7a66c4894ffc1d37e4250f7a
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jun 26 21:32:11 2014 +0200
Add getbsize() function
Import code from DragonFlyBSD and man page from FreeBSD.
include/bsd/stdlib.h | 2 +
man/Makefile.am | 1 +
man/getbsize.3 | 95 +++++++++++++++++++++++++++++++++++++++++++++++
src/Makefile.am | 1 +
src/getbsize.c | 102 +++++++++++++++++++++++++++++++++++++++++++++++++++
src/libbsd.map | 2 +
6 files changed, 203 insertions(+)
commit a88bb8380db5343c57130ac80c787c7869eae3c7
Author: Christian Svensson <debian@cmd.nu>
Date: Thu Mar 6 22:10:36 2014 +0100
Add OpenRISC support to nlist()
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/local-elf.h | 6 ++++++
1 file changed, 6 insertions(+)
commit 8d16c3df6799c93a7c01117b27318e864e34c5a2
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Oct 11 05:43:42 2013 +0200
Add timeconv module from FreeBSD
Inline license information from FreeBSD root dir COPYRIGHT file.
COPYING | 9 ++++
include/Makefile.am | 1 +
include/bsd/timeconv.h | 57 +++++++++++++++++++++++
src/Makefile.am | 1 +
src/libbsd.map | 9 ++++
src/timeconv.c | 119 +++++++++++++++++++++++++++++++++++++++++++++++++
6 files changed, 196 insertions(+)
commit f41fdcf186abbe26b11ba10fb3d4d0c1f109501e
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Oct 21 05:07:56 2013 +0200
Add funopen() function
This is a wrapper over the glibc fopencookie() function.
We diverge from the FreeBSD, OpenBSD and DragonFlyBSD declarations,
because seekfn() there wrongly uses fpos_t, assuming it's an integral
type, and any code using that on a system where fpos_t is a struct
(such as GNU-based systems or NetBSD) will fail to build. In which case,
as the code has to be modified anyway, we might just as well use the
correct declaration.
configure.ac | 2 +-
include/bsd/stdio.h | 17 +++++
man/Makefile.am | 1 +
man/funopen.3 | 191 ++++++++++++++++++++++++++++++++++++++++++++++++++++
src/Makefile.am | 1 +
src/funopen.c | 142 ++++++++++++++++++++++++++++++++++++++
src/libbsd.map | 4 ++
test/.gitignore | 1 +
test/Makefile.am | 2 +
test/funopen.c | 178 ++++++++++++++++++++++++++++++++++++++++++++++++
10 files changed, 538 insertions(+), 1 deletion(-)
commit 86cbff385a756f428091441674a5867603b1c910
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Oct 11 05:11:42 2013 +0200
Handle glibc partial header inclusions
The glibc headers use selective inclusions through the __need_NAME
mechanism to avoid circular dependencies.
The problem is that if we are being overlaid, and have been requested
a partial inclusion, when we pass control to the system header, then
we might miss definitions needed by our own header, resulting in build
failures.
Workaround that by catching current partial requests, and skip the
current inclusion.
include/bsd/stdio.h | 9 ++++++++-
include/bsd/wchar.h | 10 +++++++++-
2 files changed, 17 insertions(+), 2 deletions(-)
commit ee04e8de14e49f9cf2bf2f7c90e1314c6ba0e500
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Oct 10 09:49:04 2013 +0200
build: Set subdir-objects automake option
Bump automake minimal version to 1.9.
.gitignore | 1 +
configure.ac | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
commit 61b2dbb8f5ee52c4a50918e0a9c40300678bae50
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jul 15 01:44:30 2013 +0200
Fix dehumanize_number() to correctly detect overflows
Do not allow numbers greated than INT64_MAX and smaller than INT64_MIN.
Clarify the positive sign value by prefixing it with an explicit +.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=66909
src/dehumanize_number.c | 14 ++++++++++----
test/humanize.c | 13 +++++++++++++
2 files changed, 23 insertions(+), 4 deletions(-)
commit 119417462e21b71a2c5818a7ba8837e1caaa2b7a
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jul 14 10:58:20 2013 +0200
Release libbsd 0.6.0
configure.ac | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 948bcf1db8aca0b500174d487da3bcf3977838eb
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 13 02:11:20 2013 +0200
Warn when setproctitle() gets called before initialization
Try to give a helpful message in case the program is not initializing
the setproctitle() machinery.
src/setproctitle.c | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
commit c5b959028734ca2281250c85773d9b5e1d259bc8
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jul 11 12:25:54 2013 +0200
Move setproctitle() automatic initialization to its own library
The automatic initialization cannot be part of the main shared library,
because there is no thread-safe way to change the environ global
variable. This is not a problem if the initializaion happens just at
program load time, but becomes one if the shared library is directly or
indirectly dlopen()ed during the execution of the program, which could
have either kept references to the old environ or could change it in
some other thread. This has been observed for example on systems using
Samba NSS modules.
To avoid any other possible fallout, the constructor is split into a
new static library that needs to be linked explicitly into programs
using setproctitle(). As an additional safety measure the pkg-config
linker flags will mark the program as not allowing to be dlopen()ed
so that we avoid the problem described above.
Reported-by: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=66679
configure.ac | 1 +
include/bsd/unistd.h | 4 ++
man/setproctitle.3 | 16 +++++++
src/Makefile.am | 7 +++
src/libbsd-ctor.pc.in | 12 +++++
src/libbsd.map | 5 +++
src/setproctitle.c | 12 +----
include/bsd/unistd.h => src/setproctitle_ctor.c | 60 ++++++++++---------------
test/Makefile.am | 6 ++-
9 files changed, 76 insertions(+), 47 deletions(-)
commit 3077d2fffc55aff310eb4f5e2bb82ba176bce5c1
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jul 12 22:15:58 2013 +0200
build: Move version ABI from Makefile to configure.ac
It's easier to find there, and the value can be reused in case we have
to provide another shared library.
configure.ac | 7 +++++++
src/Makefile.am | 2 +-
2 files changed, 8 insertions(+), 1 deletion(-)
commit 1bf0a55579d823fadccb1ff2d58770cbb404c810
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jun 8 17:43:42 2013 +0200
Release libbsd 0.5.2
src/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit ad613d9d09e12c2397d8804c66f65ff1f89eed64
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 7 07:11:50 2013 +0200
Create a shallow copy of environ before replacing it in setproctitle()
Because clearenv() or setenv() might free the environ array of pointers,
we should make sure to copy it so that we can access it later on when
doing the deep copy via setenv().
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=65470
src/setproctitle.c | 43 ++++++++++++++++++++++++++++++++++---------
1 file changed, 34 insertions(+), 9 deletions(-)
commit e084ce3fa75d38067c3f0b2a4c73410070742238
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 7 04:46:29 2013 +0200
Specify setproctitle_stub() signature manually if typeof is missing
Do not stop exporting the function in the version node even if typeof
is not available, as that would break ABI.
src/setproctitle.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
commit 50e4c55afddad7f1001c80f3682ea7400a808747
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jun 8 17:55:19 2013 +0200
Try to check if setproctitle() constructor got passed arguments
src/setproctitle.c | 4 ++++
1 file changed, 4 insertions(+)
commit 6faea4d2a0eb7782187dd6d92749a0813e7405bd
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed May 29 02:23:56 2013 +0200
Force setproctitle() into .init_array section
The GNU .init_array support is an extension over the standard System V
ABI .init_array support, which passes the main() arguments to the init
function.
This support comes in three parts. First the dynamic linker (from glibc)
needs to support it. Then function pointers need to be placed in the
section, for example by using __attribute__((constructor)), that the
compiler (gcc or clang for example) might place in section .ctors and
the linker (from binutils) will move to .init_array on the output
object, or by placing them directly into .init_array by the compiler
when compiling. If this does not happen and the function pointers end
up in .ctors, then they will not get passed the main() arguments, which
we do really need in this case.
But this relies on recent binutils or gcc having native .init_array
support, and not having it disabled through --disable-initfini-array.
To guarantee we get the correct behaviour, let's just place the function
pointer in the .init_array section directly, so we only require a recent
enough glibc.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=65029
configure.ac | 45 +++++++++++++++++++++++++++++++++++++++++++++
src/setproctitle.c | 12 ++++++++++--
2 files changed, 55 insertions(+), 2 deletions(-)
commit 367e036537109f8955221123af0569329868edf1
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jun 8 08:15:21 2013 +0200
test: Try setting and getting an environment variable after setproctitle()
COPYING | 2 +-
test/proctitle.c | 8 +++++++-
2 files changed, 8 insertions(+), 2 deletions(-)
commit dc8b09783f429a7d1c6d69f1fec8e55b943577f4
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu May 30 04:09:25 2013 +0200
build: Ignore automake 1.13+ test suite generated files
.gitignore | 2 ++
1 file changed, 2 insertions(+)
commit 46633647838505c22fa4a5523a3013c3470e3861
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 27 06:52:05 2013 +0200
Release libbsd 0.5.1
src/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit df5aebd7e139e588c67c1f299bbcc6231cab0ab7
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 27 06:49:57 2013 +0200
test: Mark a literal integer as long long
This fixes build failures on 32-bit architectures.
test/humanize.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 9587882316f91ab880bf0ad9df2f0f98f2747f7c
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue May 21 04:34:34 2013 +0200
Release libbsd 0.5.0
src/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 01f146c28e3c0d4dd9844c7b454b37aa4d12f45b
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 27 04:41:58 2013 +0200
build: Handle the ChangeLog as a distributed-only file
The ChangeLog file is distributed, and cannot be regenerated outside
of the git repository, so do not remove it in DISTCLEANFILES, and move
the generation code into dist-hook, which also avoids unnecessary
computation during normal builds.
Makefile.am | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
commit 509841b53319068d8e943d5584288ad2042e3b3c
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat May 25 15:44:57 2013 +0200
build: Use AM_V_at for mkdir
src/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 06f0585c4855fac5f219ba0d99fbaf0f3e8f65e1
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue May 21 10:31:59 2013 +0200
build: Compress the distribution tarball with xz instead of gzip
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 7c4caa679a5065d1a34608c583c479a6e66a37e3
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat May 25 15:36:11 2013 +0200
Fix comparison between signed and unsigned integer compiler warnings
src/heapsort.c | 2 +-
src/nlist.c | 3 ++-
src/radixsort.c | 2 +-
3 files changed, 4 insertions(+), 3 deletions(-)
commit 30349f8922db271043ec334a719f9910f79eecf1
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat May 25 15:35:39 2013 +0200
Update radixsort module from NetBSD
Merge some interesting changes.
man/radixsort.3 | 23 ++++++++++++-------
src/radixsort.c | 68 +++++++++++++++++++++++++--------------------------------
2 files changed, 45 insertions(+), 46 deletions(-)
commit 96a2dae3525ba28cea954d6d445bb2d03c0cff66
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat May 25 15:31:45 2013 +0200
Update setmode module from NetBSD
Merge some interesting changes.
man/setmode.3 | 91 +++++++++++++++++++++++++++++++++++++++++----------------
src/setmode.c | 94 +++++++++++++++++++++++++++++++++++++----------------------
2 files changed, 125 insertions(+), 60 deletions(-)
commit a4812cdf240fac5d0461288094cc94e03e030272
Author: Casper Dik <casper.dik@oracle.com>
Date: Fri Mar 15 01:13:58 2013 +0100
Fix getpeereid() compilation on Solaris
The code in getpeereid() is unlikely to compile as ucred_t is an opaque
struct (ucred_t * works but ucred_t does not). Either you need to give
a pointer initialized to NULL and getpeerucred() allocates a new ucred
or you call it with an allocated ucred as in this patch.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
src/getpeereid.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
commit d3a09e1cf4daa6f8a2eededa55ff4c812e11e858
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Dec 27 11:19:20 2012 +0100
Switch dehumanize_number() to use expand_number()
The function is a duplicate of expand_number(), but covering less
prefixes and with a slightly different function signature.
Spotted-by: Peter da Silva <resuna@gmail.com>
COPYING | 2 +-
src/dehumanize_number.c | 124 ++++++++++++++----------------------------------
2 files changed, 37 insertions(+), 89 deletions(-)
commit 330b569fe3333f91eb7c0192ab0c5af7e15c616f
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun May 26 04:34:57 2013 +0200
test: Add new humanize unit test
test/.gitignore | 1 +
test/Makefile.am | 2 ++
test/humanize.c | 64 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 67 insertions(+)
commit 8c26c40ad2cc606a3ac1a4f7ea50d72864d21f17
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Nov 27 14:23:26 2012 +0100
test: Add setproctitle() unit test
test/.gitignore | 1 +
test/Makefile.am | 2 ++
test/proctitle.c | 48 ++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 51 insertions(+)
commit e9933255d4234a7d16f5e2f261376dd10747d469
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat May 25 17:11:53 2013 +0200
Make setproctitle() available in 0.2 and 0.5 version nodes
Make the 0.5 version the default, so that code wanting the actual
implemented version can get a proper versioned depdendency. For code
linked against the old version, make it available as an alias.
configure.ac | 1 +
src/libbsd.map | 5 +++--
src/setproctitle.c | 12 +++++++++++-
3 files changed, 15 insertions(+), 3 deletions(-)
commit c984dacd65920b2f48cf0f4e579030488799f496
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Nov 27 14:24:13 2012 +0100
Implement sendmail semantics for setproctitle()
Prefix the title with "progname: ", and skip it if the format string
starts with '-' (which gets skipped on output too).
src/setproctitle.c | 12 +++++++++++-
1 file changed, 11 insertions(+), 1 deletion(-)
commit 35785f8dd1be73ef8e08c18a88e77e00fe332b6c
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Nov 25 21:10:53 2012 +0100
Modify setproctitle() to conform to project coding style
Use local getprogname()/setprogname() instead of reimplementing them
locally. Use clearenv() if available, not just on glibc. Use bool
instead of _Bool. Use paranthesis on sizeof. Fold the SPT_MIN macro
into spt_min(). Make spt_init() static. Avoid unnecessary gotos.
COPYING | 1 +
configure.ac | 2 +-
src/setproctitle.c | 219 ++++++++++++++++++++++++-----------------------------
3 files changed, 99 insertions(+), 123 deletions(-)
commit 2a0260d08c5f9ecc43fef99c4e180c0d977deba5
Author: William Ahern <william@25thandClement.com>
Date: Wed Nov 28 11:09:02 2012 +0100
Add a setproctitle() implementation
Taken from libnostd.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
COPYING | 23 +++++
src/setproctitle.c | 284 +++++++++++++++++++++++++++++++++++++++++++++++------
2 files changed, 279 insertions(+), 28 deletions(-)
commit f8d52ead5e913a74a44351f7a805987bfda0ac18
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Nov 23 18:33:23 2012 +0100
Add x32 support to nlist()
src/local-elf.h | 4 ++++
1 file changed, 4 insertions(+)
commit cf683a275a13c2d8bd0ebc9a5953bb974aba3fae
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Nov 23 18:32:35 2012 +0100
Add arm64 (aka aarch64) to nlist()
src/local-elf.h | 12 +++++++++++-
1 file changed, 11 insertions(+), 1 deletion(-)
commit 7196b4dccaaa796dd96358162fdf143393162a8d
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu May 23 02:05:19 2013 +0200
test: Add new fgetln() and fgetwln() unit test
test/.gitignore | 1 +
test/Makefile.am | 3 +
test/fgetln.c | 263 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 267 insertions(+)
commit a97ce513e031b29a47965b740be14fb9a84277fc
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Nov 23 21:19:45 2012 +0100
Add new fgetwln() function
Man page taken from FreeBSD.
include/bsd/wchar.h | 2 +
man/Makefile.am | 1 +
man/fgetwln.3 | 117 +++++++++++++++++++++++++++++++++++
src/Makefile.am | 1 +
include/bsd/wchar.h => src/fgetwln.c | 70 ++++++++++++++++-----
src/libbsd.map | 1 +
6 files changed, 178 insertions(+), 14 deletions(-)
commit ee0489eb2bd09298f547c57a59f28dcd094d781e
Author: Strake <strake888@gmail.com>
Date: Tue Aug 7 08:44:30 2012 -0500
Add new fparseln() function
Taken from NetBSD.
[guillem@hadrons.org:
- Import from NetBSD instead of FreeBSD to get a 3-clause BSD license,
instead of a 4-clause one.
- Define compatibility macros.
- Change library from libc to libbsd and header in man page.
- Add copyright information to COPYING.
- Add symbol to map file. ]
Signed-off-by: Guillem Jover <guillem@hadrons.org>
COPYING | 3 +
include/bsd/libutil.h | 13 +++
man/Makefile.am | 1 +
man/fparseln.3 | 149 ++++++++++++++++++++++++++++++++
src/Makefile.am | 1 +
src/fparseln.c | 230 ++++++++++++++++++++++++++++++++++++++++++++++++++
src/libbsd.map | 2 +
7 files changed, 399 insertions(+)
commit cb7bc0d85ea9ec5eb8e9c922c2ad0ea7498620e9
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Nov 25 22:09:43 2012 +0100
Add file buffer pool support to fgetln()
This avoids buffer overwrites during concurrent or intermixed calls to
fgetln() when using more than one different stream (currently 32), which
the original interface supports natively by using an internal buffer
from the FILE structure. Although this workaround is rudimentary, it
should cover most of the theoretically problematic cases.
COPYING | 2 +-
src/fgetln.c | 30 +++++++++++++++++++++++++-----
2 files changed, 26 insertions(+), 6 deletions(-)
commit 1be0bdb2c98be6ce1126fd2b400060198c78a8e3
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Nov 25 21:13:38 2012 +0100
Add new strnstr() function
Taken from FreeBSD.
COPYING | 4 ++
include/bsd/string.h | 1 +
man/Makefile.am | 1 +
man/strnstr.3 | 110 +++++++++++++++++++++++++++++++++++++++++++++++++++
src/Makefile.am | 1 +
src/libbsd.map | 2 +
src/strnstr.c | 65 ++++++++++++++++++++++++++++++
7 files changed, 184 insertions(+)
commit ff0d700df095a4eb2091ccf197d213e43a89edd4
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Nov 23 17:16:43 2012 +0100
Add new wcslcat() and wcslcpy() functions
Taken from FreeBSD.
include/Makefile.am | 1 +
include/bsd/wchar.h | 45 ++++++++++++++++++++++++++++++++
man/Makefile.am | 2 ++
man/wcslcat.3 | 1 +
man/wcslcpy.3 | 67 ++++++++++++++++++++++++++++++++++++++++++++++++
src/Makefile.am | 2 ++
src/libbsd.map | 5 ++++
src/wcslcat.c | 74 +++++++++++++++++++++++++++++++++++++++++++++++++++++
src/wcslcpy.c | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++
9 files changed, 267 insertions(+)
commit 386276487229a5ee0635130e4886f1d89b1c31d0
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue May 21 04:13:55 2013 +0200
Coalesce identical BSD-2-clause licenses
COPYING | 163 ++++++----------------------------------------------------------
1 file changed, 13 insertions(+), 150 deletions(-)
commit 918a4dba4a35fdc241381a2ff9f1e697653adf88
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 27 09:15:15 2012 +0200
Release libbsd 0.4.2
src/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 444bd1fbb8f53047b1ee2b69dc4a8eb65537bc68
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jun 21 10:16:14 2012 +0200
man: Use minus signs and hyphens consistently
Any string that can be copy & pasted into a terminal, for example,
needs to correctly use minus signs (escaped dashes), instead of the
default hyphen.
man/flopen.3 | 2 +-
man/pidfile.3 | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
commit 1d69ae1cd56855b0e9cf5c40f24854f77d9009ca
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jun 4 05:47:26 2012 +0200
man: Recode flopen(3) to UTF-8
Spotted-by: Eric Smith <eric@brouhaha.com>
man/flopen.3 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 14524b545d7b3f3f8c01405e9ef5ba45d438424c
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jun 3 07:39:42 2012 +0200
build: Set default compiler variables from configure
This centralizes the setting so there's no duplication anymore,
makes sure the user supplied variables are never overridden, and
are only set when using gcc.
Reported-by: Samuli Suominen <ssuominen@gentoo.org>
configure.ac | 8 ++++++++
src/Makefile.am | 3 ---
test/Makefile.am | 3 ---
3 files changed, 8 insertions(+), 6 deletions(-)
commit c21d788fea18ddb8f6eb309c73783df5ccd6bf53
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 1 08:20:37 2012 +0200
Release libbsd 0.4.1
src/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit fdcae5770799b232d50bf311d69c375f730a1ed3
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 1 08:17:42 2012 +0200
build: Set runtimelibdir to libdir
This makes sure the install-exec-hook under src works as expected even
when no runtimelibdir was specified, otherwise the symlinks end up
pointing to non-existing targets.
Reported-by: Ryan Mullen <rmmullen@gmail.com>
src/Makefile.am | 2 ++
1 file changed, 2 insertions(+)
commit e9e4a60d7e18c103be6df33cbbeaf249578a1ac5
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 1 08:15:00 2012 +0200
build: Use MKDIR_P variable instead of literal «mkdir -p»
src/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 309c82a016d5cfc84d71066f21edc7cd7f5ab95d
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue May 29 04:38:07 2012 +0200
Release libbsd 0.4.0
src/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit cd67cb14173b4329d4cb8c74ea88240e5e4bf2c3
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue May 29 07:17:46 2012 +0200
Use implicit <md5.h> from overlay instead explicit <bsd/md5.h>
This was assuming an installed <bsd/md5.h> on the system, due to the
build system not including -Iinclude/ anymore.
Regression introduced in commit 901ed630fc64fca828e031bc8fa6780db9f05db1.
src/Makefile.am | 2 +-
src/hash/md5.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
commit 1b5b1cd52ab0209d6213f02ba62fbb959d534fd2
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Apr 24 04:20:58 2012 +0200
Move mdX.3 man page to section 3bsd
This makes sure there will be no collisions on systems where a mdX.3
provided by a third party is already present.
man/Makefile.am | 4 ++--
man/{mdX.3 => mdX.3bsd} | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
commit ddefaae330f95d89cd1046bdde43d51fd0783c1b
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Apr 24 04:05:48 2012 +0200
Do not quote man page titles
man/flopen.3 | 2 +-
man/pidfile.3 | 2 +-
man/strtonum.3 | 2 +-
man/tree.3 | 2 +-
4 files changed, 4 insertions(+), 4 deletions(-)
commit e7f3976088b038687e54a2df09cb9e3332af42df
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Mar 23 10:31:42 2012 +0100
Add email address to my name
COPYING | 2 +-
include/bsd/bsd.h | 2 +-
include/bsd/err.h | 2 +-
include/bsd/getopt.h | 2 +-
include/bsd/nlist.h | 2 +-
include/bsd/stdio.h | 2 +-
include/bsd/stdlib.h | 2 +-
include/bsd/string.h | 2 +-
include/bsd/sys/cdefs.h | 2 +-
include/bsd/sys/endian.h | 2 +-
include/bsd/sys/poll.h | 2 +-
include/bsd/unistd.h | 2 +-
src/fgetln.c | 2 +-
src/fpurge.c | 2 +-
src/getpeereid.c | 2 +-
src/local-elf.h | 2 +-
src/setproctitle.c | 2 +-
17 files changed, 17 insertions(+), 17 deletions(-)
commit e59ac2c96c4f9299912868cd86fa650639050f78
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Mar 23 10:11:57 2012 +0100
Clarify that the 4-clause BSD licenses are only for man pages
COPYING | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
commit 7cfa7e4304756151b7987a62fb304300f1205a42
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jan 12 19:13:16 2012 +0100
Add new man page for tree(3)
Taken from FreeBSD.
man/Makefile.am | 1 +
man/tree.3 | 504 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 505 insertions(+)
commit 7620fef70bac36435dae756554f575826cb89f8b
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jan 12 20:56:24 2012 +0100
Remove UC Berkeley advertising clause
As per <ftp://ftp.cs.berkeley.edu/pub/4bsd/README.Impt.License.Change>.
man/bitstring.3 | 4 ----
man/queue.3bsd | 4 ----
2 files changed, 8 deletions(-)
commit 08139dd50e6b728a1d9052e852799f60a7f8482d
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jan 12 19:13:16 2012 +0100
Add new man pages for bitstring(3) and queue(3)
Taken from FreeBSD.
man/Makefile.am | 2 +
man/bitstring.3 | 190 ++++++++++
man/queue.3bsd | 1044 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 1236 insertions(+)
commit d90ce079f727a8595dbc953e62dbc119e3914c53
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat May 14 14:18:57 2011 +0200
Add new man pages for getprogname(3) and setprogname(3)
Taken from FreeBSD.
COPYING | 32 +++++++++++++++++++
man/Makefile.am | 2 ++
man/getprogname.3 | 95 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
man/setprogname.3 | 1 +
4 files changed, 130 insertions(+)
commit c1d086c224c1c98832d448a3e817767530d22e71
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat May 14 14:18:57 2011 +0200
Add new man page for setproctitle(3)
Taken from FreeBSD.
COPYING | 21 +++++++++
man/Makefile.am | 1 +
man/setproctitle.3 | 124 +++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 146 insertions(+)
commit e37293a18a55e5c3be33725527f65ccb4025ca6c
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jan 12 18:16:55 2012 +0100
Add <bitstring.h> for compatibility with NetBSD and OpenBSD
include/Makefile.am | 1 +
include/bsd/bitstring.h | 32 ++++++++++++++++++++++++++++++++
2 files changed, 33 insertions(+)
commit 34bf1068a27add441a0d6ef90ead4ed644c71c80
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Mar 23 10:43:33 2012 +0100
test: Add a unit test for endian encoder/decoder
test/.gitignore | 1 +
test/Makefile.am | 1 +
test/endian.c | 68 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 70 insertions(+)
commit 4eab0cc35130d182e5ab54ab13a0c9a0a8405886
Author: Robert Millan <rmh@debian.org>
Date: Tue Jan 3 05:29:36 2012 +0100
Add inline endian encoding/decoding functions
Taken from FreeBSD.
Signed-off-by: Guillem Jover <guillem@hadrons.org>
COPYING | 26 +++++++++
include/bsd/sys/endian.h | 136 +++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 162 insertions(+)
commit 752997462a922402531c92b22dd7ab5af352f408
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jan 3 08:58:01 2012 +0100
Base getprogname() on program_invocation_short_name presence instead of glibc
configure.ac | 9 +++++++++
src/progname.c | 2 +-
2 files changed, 10 insertions(+), 1 deletion(-)
commit d5d91869372f50d755cfa66803a52eece02dee43
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jan 3 09:08:35 2012 +0100
Base fpurge() implementation on __fpurge presence instead of glibc
configure.ac | 2 +-
src/fpurge.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
commit f8e80630796cd65ada70f9bf49a8737cfcd444ca
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jan 3 08:40:18 2012 +0100
Base fgetln() implementation on getline presence instead of glibc
configure.ac | 2 +-
src/fgetln.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
commit 786d1439207b689fb0219ab38f535891ec90dbf1
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Mar 24 20:37:55 2012 +0100
test: Add new overlay unit test
test/.gitignore | 1 +
test/Makefile.am | 1 +
test/overlay.c | 23 +++++++++++++++++++++++
3 files changed, 25 insertions(+)
commit 866f73af914ba72815cb94d6c42ba4620fb22350
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jan 3 05:39:22 2012 +0100
Move overlay inclusions outside of header protection
Glibc tends to include standard headers with special definitions
that make few declarations or macros visible, this stomps over the
overlay #include_next <> logic.
Based-on-patch-by: Robert Millan <rmh@debian.org>
include/bsd/err.h | 12 ++++++------
include/bsd/getopt.h | 5 -----
include/bsd/stdio.h | 12 ++++++------
include/bsd/stdlib.h | 14 +++++++-------
include/bsd/string.h | 12 ++++++------
include/bsd/sys/cdefs.h | 6 +++---
include/bsd/sys/endian.h | 6 +++---
include/bsd/sys/poll.h | 6 +++---
include/bsd/unistd.h | 12 ++++++------
9 files changed, 40 insertions(+), 45 deletions(-)
commit f71d8e050178ab23ab9b06ee4ccab901ce4284bf
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Mar 21 04:10:37 2012 +0100
Remove bogus deprecation warning from <getopt.h>
include/bsd/getopt.h | 1 -
1 file changed, 1 deletion(-)
commit 0b96e1a218b700448adf3c016ab25c11f207f6f6
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jan 3 07:32:53 2012 +0100
Remove deprecated compatibility includes in headers
include/bsd/bsd.h | 5 -----
include/bsd/stdlib.h | 11 -----------
include/bsd/string.h | 9 ---------
3 files changed, 25 deletions(-)
commit 109cafb3932c5c74500e1f53e54059670a173cfb
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jan 3 07:32:37 2012 +0100
Remove deprecated headers
include/Makefile.am | 8 --------
include/bsd/cdefs.h | 42 ------------------------------------------
include/bsd/inet.h | 38 --------------------------------------
include/bsd/ip_icmp.h | 42 ------------------------------------------
include/bsd/queue.h | 42 ------------------------------------------
include/bsd/random.h | 42 ------------------------------------------
include/libutil.h | 38 --------------------------------------
include/nlist.h | 38 --------------------------------------
include/vis.h | 38 --------------------------------------
9 files changed, 328 deletions(-)
commit 64348583148e2ae3b97e27916b90bbbe0b74461e
Author: Robert Millan <rmh@debian.org>
Date: Sat Dec 31 04:30:48 2011 +0100
Add new expand_number() function
Taken from FreeBSD.
[guillem@hadrons.org:
- Include <stdint.h> in <bsd/libutil.h>. ]
Signed-off-by: Guillem Jover <guillem@hadrons.org>
COPYING | 27 ++++++++++++++
include/bsd/libutil.h | 2 +
man/Makefile.am | 1 +
man/expand_number.3 | 87 +++++++++++++++++++++++++++++++++++++++++++
src/Makefile.am | 1 +
src/expand_number.c | 101 ++++++++++++++++++++++++++++++++++++++++++++++++++
src/libbsd.map | 1 +
7 files changed, 220 insertions(+)
commit 943939d0e57257c83a8113102eb9e9703963cc5c
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Dec 31 08:39:44 2011 +0100
Add new closefrom() function
Code taken from sudo, man page from FreeBSD.
COPYING | 30 ++++++++++++-
configure.ac | 10 ++++-
include/bsd/unistd.h | 2 +
man/Makefile.am | 1 +
man/closefrom.3 | 54 +++++++++++++++++++++++
src/Makefile.am | 1 +
src/closefrom.c | 122 +++++++++++++++++++++++++++++++++++++++++++++++++++
src/libbsd.map | 4 ++
8 files changed, 222 insertions(+), 2 deletions(-)
commit 3d614131b598e52b34c487866dae4853df5ec86a
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Dec 31 06:01:27 2011 +0100
Base errc() and warnc() on vwarnc() and verrc() respectively
src/err.c | 13 +++----------
1 file changed, 3 insertions(+), 10 deletions(-)
commit 87232260404f10c6884756796306f270a527628e
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 6 16:29:26 2011 +0200
Use system __progname variable in progname module if available
configure.ac | 9 +++++++++
src/progname.c | 4 ++++
2 files changed, 13 insertions(+)
commit b5cc17d66498c3da0aa862a517f630b4aa5d5dc6
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jul 5 23:27:31 2011 +0200
Use getexecname() if available for getprogname()
This function is present on Solaris.
configure.ac | 1 +
src/progname.c | 6 +++++-
2 files changed, 6 insertions(+), 1 deletion(-)
commit abf14c3940a5ec08bb9fce9ddfb7375309a4d97f
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Mar 24 20:37:55 2012 +0100
test: Add new headers unit test
test/.gitignore | 1 +
test/Makefile.am | 1 +
test/headers.c | 25 +++++++++++++++++++++++++
3 files changed, 27 insertions(+)
commit 23973e2221628ba038119957543a49d72c8376d7
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Mar 23 10:43:33 2012 +0100
build: Add a test suite infrastructure
Makefile.am | 2 +-
configure.ac | 1 +
test/Makefile.am | 16 ++++++++++++++++
3 files changed, 18 insertions(+), 1 deletion(-)
commit 980f04f77b7ddfcd047ef77b30677b678bebf711
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jan 3 08:58:52 2012 +0100
build: Do not define already defined _GNU_SOURCE
The macro is defined by configure on config.h which is now implicitly
included by all source files.
src/Makefile.am | 2 +-
src/fpurge.c | 2 --
2 files changed, 1 insertion(+), 3 deletions(-)
commit 8d2f12d7f032312dd509599a867296059d5bfef7
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jan 3 08:45:05 2012 +0100
build: Include <config.h> through -include for all source files
src/Makefile.am | 1 +
1 file changed, 1 insertion(+)
commit 88004b30ff173caac5d76f6d65750bb4144f3cec
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Dec 31 07:31:47 2011 +0100
build: Set -Wno-unused-parameter to default CFLAGS
src/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit dcaa93d9843d6e0ac77c48541036a69bc4cadd21
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Dec 17 11:13:04 2010 +0100
build: Switch to autotools
.gitignore | 13 +++
Makefile | 237 ----------------------------------------------------
Makefile.am | 19 +++++
autogen | 5 ++
configure.ac | 50 +++++++++++
get-version | 3 +-
include/Makefile.am | 31 +++++++
man/Makefile.am | 45 ++++++++++
src/Makefile.am | 85 +++++++++++++++++++
9 files changed, 250 insertions(+), 238 deletions(-)
commit 0aa777f47e6ed96c963cc6de4aee7e78f8f9b07f
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Dec 31 07:35:52 2011 +0100
Move .pc and .map files to src/
Makefile | 6 +++---
libbsd-overlay.pc.in => src/libbsd-overlay.pc.in | 0
libbsd.map => src/libbsd.map | 0
libbsd.pc.in => src/libbsd.pc.in | 0
4 files changed, 3 insertions(+), 3 deletions(-)
commit 540ab03b1802bdad34999a5b5042d1b476588e39
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Dec 31 06:50:40 2011 +0100
Move man pages to man/
Makefile | 6 +++---
{src => man}/.gitignore | 0
{src => man}/arc4random.3 | 0
{src => man}/arc4random_addrandom.3 | 0
{src => man}/arc4random_buf.3 | 0
{src => man}/arc4random_stir.3 | 0
{src => man}/arc4random_uniform.3 | 0
{src => man}/dehumanize_number.3 | 0
{src => man}/fgetln.3 | 0
{src => man}/flopen.3 | 0
{src => man}/fmtcheck.3 | 0
{src => man}/getmode.3 | 0
{src => man}/getpeereid.3 | 0
{src => man}/heapsort.3 | 0
{src => man}/humanize_number.3 | 0
{src => man}/mdX.3 | 0
{src => man}/mergesort.3 | 0
{src => man}/nlist.3 | 0
{src => man}/pidfile.3 | 0
{src => man}/radixsort.3 | 0
{src => man}/readpassphrase.3 | 0
{src => man}/reallocf.3 | 0
{src => man}/setmode.3 | 0
{src => man}/sradixsort.3 | 0
{src => man}/strlcat.3 | 0
{src => man}/strlcpy.3 | 0
{src => man}/strmode.3 | 0
{src => man}/strtonum.3 | 0
{src => man}/unvis.3 | 0
{src => man}/vis.3 | 0
30 files changed, 3 insertions(+), 3 deletions(-)
commit 93321224f66d65acfade35305c454d5887fc9f07
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Dec 11 07:57:05 2011 +0100
Rename version script from Versions to libbsd.map
Makefile | 2 +-
Versions => libbsd.map | 0
2 files changed, 1 insertion(+), 1 deletion(-)
commit 2fb7200d4505dbd4ec44c9937e86652a30eb782e
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Oct 23 19:27:44 2011 +0200
Fix typos in source comments
Found by codespell.
src/heapsort.c | 2 +-
src/nlist.c | 6 +++---
src/pidfile.c | 2 +-
3 files changed, 5 insertions(+), 5 deletions(-)
commit 0acd86f6eb1637b54911428d067e15c9a414c883
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jul 5 21:01:57 2011 +0200
build: Use -isystem instead of -I
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 901ed630fc64fca828e031bc8fa6780db9f05db1
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jul 5 21:01:18 2011 +0200
build: Do not add -Iinclude/ to MK_CPPFLAGS
The source code should not be using any of the headers there.
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 059f89ca95991d5570980846020385f8947be60e
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Jul 5 20:59:04 2011 +0200
Add missing semicolon to bsd_getopt() declaration
Accidentally lost in commit 4a6303ba3b64504ab0077b9cfebd2a4b918d531d.
include/bsd/unistd.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 4a6303ba3b64504ab0077b9cfebd2a4b918d531d
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 8 02:10:38 2011 +0200
Constify bsd_getopt(3) arguments
This matches the standard declaration for getopt(3).
include/bsd/unistd.h | 2 +-
src/bsd_getopt.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
commit 7446f029b52f15b318402c3827802cdf31727566
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jun 2 19:16:57 2011 +0200
Release libbsd 0.3.0
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit e80d338b180e499ccfa92a03e0a71b9d7abfb382
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jun 2 19:14:44 2011 +0200
Add a COPYING file to ease the distributors work
This file includes all the copyright and license notices from the source
code in a single place.
COPYING | 444 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 444 insertions(+)
commit b891772ad6c26a30f4ae0e1d3ead306c2eab6fd1
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun May 29 02:49:14 2011 +0200
Remove blank lines at EOF
Makefile | 1 -
README | 1 -
Versions | 1 -
get-version | 1 -
include/bsd/cdefs.h | 1 -
include/bsd/inet.h | 1 -
include/bsd/ip_icmp.h | 1 -
include/bsd/nlist.h | 1 -
include/bsd/queue.h | 1 -
include/bsd/random.h | 1 -
src/fgetln.c | 1 -
src/local-elf.h | 1 -
src/setproctitle.c | 1 -
13 files changed, 13 deletions(-)
commit b0eb19970a2953e4f689e4d7584e78595ef93622
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat May 28 11:40:36 2011 +0200
Move bsd_getopt() from <bsd/getopt.h> to <bsd/unistd.h>
Deprecate <bsd/getopt.h>.
include/bsd/getopt.h | 19 ++++---------------
include/bsd/unistd.h | 10 ++++++++++
2 files changed, 14 insertions(+), 15 deletions(-)
commit 0bf3d3913fe2adb5974add44f93a5de78bd06710
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat May 28 10:39:54 2011 +0200
Include the correct deprecated headeres when using the overlay
include/bsd/cdefs.h | 4 ++++
include/bsd/ip_icmp.h | 4 ++++
include/bsd/queue.h | 4 ++++
include/bsd/random.h | 4 ++++
include/bsd/stdlib.h | 5 +++++
include/bsd/string.h | 4 ++++
6 files changed, 25 insertions(+)
commit 913cdd91b1d696e02dff22273b7721d8dad4bf2a
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat May 28 06:35:18 2011 +0200
Do not use the same header inclusion protector for <nlist.h> and <bsd/nlist.h>
Regression introduced in commit f7caf2b30da93d46528ec706dffaf5cbde5266d9.
include/nlist.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 200eeb1265ec50ef54660d054f41af71c49e57fc
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 27 21:58:20 2011 +0200
Add LIBBSD_DISABLE_DEPRECATED to deprecated headers
When enabled this will make the inclusion of deprecated headers a
fatal error so that it's easier to spot.
include/bsd/cdefs.h | 4 ++++
include/bsd/inet.h | 4 ++++
include/bsd/ip_icmp.h | 4 ++++
include/bsd/queue.h | 4 ++++
include/bsd/random.h | 4 ++++
include/libutil.h | 4 ++++
include/nlist.h | 4 ++++
include/vis.h | 4 ++++
8 files changed, 32 insertions(+)
commit fbd622971d0a22dd94cf23c93dab72f5c6a42bf6
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 27 22:11:28 2011 +0200
Condense and clarify header deprecation warnings
Mention the possibility of using libbsd-overlay.pc.
include/bsd/cdefs.h | 2 +-
include/bsd/inet.h | 2 +-
include/bsd/ip_icmp.h | 2 +-
include/bsd/queue.h | 2 +-
include/bsd/random.h | 2 +-
include/libutil.h | 2 +-
include/nlist.h | 2 +-
include/vis.h | 2 +-
8 files changed, 8 insertions(+), 8 deletions(-)
commit 755d86be011bd3fc3edb575316daed1a641ed7d4
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 27 21:39:14 2011 +0200
Rename LIBBSD_CLEAN_INCLUDES to LIBBSD_DISABLE_DEPRECATED
Makefile | 2 +-
include/bsd/bsd.h | 2 +-
include/bsd/stdlib.h | 2 +-
include/bsd/string.h | 2 +-
4 files changed, 4 insertions(+), 4 deletions(-)
commit cd4996cebe5c57120b504630832441038211f7b7
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 27 21:23:18 2011 +0200
Namespace header protector in <bsd/sys/cdefs.h> with LIBBSD_SYS_
include/bsd/sys/cdefs.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit a7dd4457f5acd43452d9aada135314c3c62eac29
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 27 21:13:18 2011 +0200
Add new <bsd/sys/poll.h> header
Makefile | 1 +
include/bsd/sys/poll.h | 40 ++++++++++++++++++++++++++++++++++++++++
2 files changed, 41 insertions(+)
commit 8be40010cea2bc38cd8a4db9acd9552836d2b4d3
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 27 20:37:10 2011 +0200
Add new <bsd/sys/endian.h> header
Makefile | 1 +
include/bsd/sys/endian.h | 52 ++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 53 insertions(+)
commit e1f2a6f86906e2dd308a280ab832349eff4fe397
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed May 25 21:27:58 2011 +0200
Add new __packed, __aligned and __nonnull attributes
include/bsd/sys/cdefs.h | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)
commit 87dd203c26f2828de9506da5a0073aa0f6593c9e
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed May 25 21:27:12 2011 +0200
Define __dead2 and __pure2 to actual gcc attributes if possible
include/bsd/sys/cdefs.h | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
commit de2062873f2b90bb8d09d213931ee1150ffd6b77
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed May 25 21:25:54 2011 +0200
Define <sys/cdefs.h> attributes conditional to the supported gcc version
include/bsd/sys/cdefs.h | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
commit 71e5db4cde2f194cc9a93d3d2e1b524bf11e7c01
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed May 25 21:02:40 2011 +0200
Define _SYS_CDEFS_H and _SYS_CDEFS_H after including <sys/cdefs.h>
This makes sure the “standard” inclusion protectors are in place, as at
least some FreeBSD kernel headers expect these to be defined to do some
sanity checks.
include/bsd/sys/cdefs.h | 10 ++++++++++
1 file changed, 10 insertions(+)
commit 9d042171749b94510b071c9e800ed0d2a4e95bb9
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed May 25 07:38:36 2011 +0200
Map getopt to bsd_getopt if we are using the overlay
This will ensure the code can safely and correctly use optreset
transparently.
include/bsd/getopt.h | 5 +++++
src/bsd_getopt.c | 6 +++++-
2 files changed, 10 insertions(+), 1 deletion(-)
commit 17a9a8472ec3f9a40ab2fcf2e21f1fa9468e0288
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed May 25 07:36:19 2011 +0200
Rename transparent support to overlay
This affects the pkg-config file now named libbsd-overlay.pc, and the
macro to use the overlay LIBBSD_OVERLAY.
Makefile | 10 +++++-----
include/bsd/err.h | 4 ++--
include/bsd/getopt.h | 4 ++--
include/bsd/stdio.h | 2 +-
include/bsd/stdlib.h | 4 ++--
include/bsd/string.h | 4 ++--
include/bsd/sys/cdefs.h | 4 ++--
include/bsd/unistd.h | 4 ++--
libbsd-transparent.pc.in => libbsd-overlay.pc.in | 4 ++--
9 files changed, 20 insertions(+), 20 deletions(-)
commit 94fe901edabdfbafc602e4d194a21c5e0f372cba
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat May 14 18:12:48 2011 +0200
Abort compilation if fgetln cannot be wrapped
src/fgetln.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
commit 28585a58bdd0308c516d2b1caee76977283942da
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat May 14 17:58:08 2011 +0200
Add fpurge function
Makefile | 1 +
Versions | 2 ++
include/bsd/stdio.h | 4 +++-
include/bsd/stdio.h => src/fpurge.c | 47 +++++++++++++++++++++++++++----------
4 files changed, 41 insertions(+), 13 deletions(-)
commit b36c59c0edbd1c215737f16d4bb83feb035d785a
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 23 12:39:58 2011 +0100
Conditionalize <time.h> inclusion from <bsd/bsd.h>
This was added long time ago to fix some software which was implicitly
depending on the header through some other header, and to avoid having
to modify such software. Conditionalize it on LIBBSD_CLEAN_INCLUDES,
so that buildability can be tested for its future removal.
include/bsd/bsd.h | 2 ++
1 file changed, 2 insertions(+)
commit 8b6a74775b918f203ceee3d70ca8b9f7e0256b5f
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 23 12:38:42 2011 +0100
Conditionalize temporary compatibility inclusions
These inclusions were in place for backward compatibility purposes,
when the headers were split so that code using them would not break.
Make it possible for applications to disable them by defining
LIBBSD_CLEAN_INCLUDES so that buildability can be tested and fixed
before they get removed in a subsequent release.
Makefile | 4 +++-
include/bsd/stdlib.h | 2 ++
include/bsd/string.h | 2 ++
src/vis.c | 1 +
4 files changed, 8 insertions(+), 1 deletion(-)
commit c594192bac39e8ec9487f729b22dc0037d58b8c5
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat May 14 14:17:44 2011 +0200
Correct library name in man pages
src/heapsort.3 | 3 ++-
src/radixsort.3 | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
commit 8478e57463db7a4f1b27d165d45de17c6d992ada
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 23 13:14:22 2011 +0100
Update libbsd header references in man pages
Point to the namespaced path for libbsd specific headers.
TODO | 1 -
src/arc4random.3 | 2 +-
src/fgetln.3 | 2 +-
src/flopen.3 | 2 +-
src/fmtcheck.3 | 2 +-
src/getpeereid.3 | 2 +-
src/heapsort.3 | 2 +-
src/humanize_number.3 | 2 +-
src/mdX.3 | 2 +-
src/nlist.3 | 2 +-
src/pidfile.3 | 2 +-
src/radixsort.3 | 2 +-
src/readpassphrase.3 | 2 +-
src/reallocf.3 | 2 +-
src/setmode.3 | 2 +-
src/strlcpy.3 | 2 +-
src/strmode.3 | 2 +-
src/strtonum.3 | 2 +-
src/unvis.3 | 2 +-
src/vis.3 | 2 +-
20 files changed, 19 insertions(+), 20 deletions(-)
commit f7caf2b30da93d46528ec706dffaf5cbde5266d9
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 23 11:07:30 2011 +0100
Move all header files to /usr/include/bsd/ and deprecate /usr/include/
First stage of the transition to avoid possible clashes with other
software by moving out of the way the remaining headers from
/usr/include/.
At least nlist.h is known to cause file conflicts with some libelf
implementations. libutil.h is not really complete and might cause
confusion if software detects its availability w/o someone actually
checking. And lastly vis.h is not known to cause any problem and it's
complete, but better be safe than sorry.
The compatibility headers will be removed in a later release.
Makefile | 3 ++
include/{ => bsd}/libutil.h | 0
include/{ => bsd}/nlist.h | 0
include/{ => bsd}/vis.h | 0
include/libutil.h | 78 ++++++++++----------------------------
include/nlist.h | 10 ++---
include/vis.h | 92 ++++++++++-----------------------------------
7 files changed, 44 insertions(+), 139 deletions(-)
commit 520682e59647eadf697e6384021e6781164b11b0
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 23 14:04:57 2011 +0100
Add support for transparent compilation
This means that software being ported should not need to be modified in
the usual case, as the libbsd headers will take over the standard
namespace and fill the missing gaps, and include the system headers.
To use this the new libbsd-transparent.pc file can be used through
pkg-config, which should end up doing the right thing.
Makefile | 7 +++++--
include/bsd/err.h | 8 +++++++-
include/bsd/getopt.h | 5 +++++
include/bsd/stdio.h | 5 +++++
include/bsd/stdlib.h | 9 +++++++++
include/bsd/string.h | 6 ++++++
include/bsd/sys/cdefs.h | 4 ++++
include/bsd/unistd.h | 6 ++++++
libbsd-transparent.pc.in | 11 +++++++++++
src/bsd_getopt.c | 2 +-
src/err.c | 2 +-
src/flopen.c | 1 -
src/progname.c | 3 +--
src/readpassphrase.c | 2 +-
14 files changed, 62 insertions(+), 9 deletions(-)
commit 4c01261f3963c51ac0ee0f2b539cbf9298e8cc26
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 23 14:15:43 2011 +0100
Move each version symbol declaration into its own line
Versions | 24 +++++++++++++++++++-----
1 file changed, 19 insertions(+), 5 deletions(-)
commit 8a99226f16b3cf638d93b23a1c80f9df2d16fd0e
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 23 14:01:06 2011 +0100
Generalize pkg-config file handling
Use a make pattern for the .pc rule to allow using more than one .pc
file. And generalize the .gitignore entry.
.gitignore | 2 +-
Makefile | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
commit 1497d34760d53777648f91b357762ba8bbb2d5ce
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Feb 25 13:52:59 2011 +0100
Initialize __progname to program_invocation_short_name
As we do not have cooperation from the crt0 code to set __progname, we
have to set it ourselves from getprogname() in case it's NULL. On GNU
systems we can use program_invocation_short_name which is actually set
on crt0.
src/progname.c | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
commit 741eb5876341c0310fe485cc9dd3af75bc9f4ab9
Author: Kevin McCarthy <signals@gentoo.org>
Date: Tue Feb 22 20:44:21 2011 +0100
Add missing prototypes for arc4random_buf and arc4random_uniform
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=34511
include/bsd/stdlib.h | 2 ++
1 file changed, 2 insertions(+)
commit 9baf9640b9af3bbdb041703e684d3928263fb363
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 22 20:19:37 2011 +0100
Add new <bsd/sys/bitstring.h> header
Taken from FreeBSD.
Makefile | 1 +
include/bsd/sys/bitstring.h | 146 ++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 147 insertions(+)
commit 4b95e82a32f07ec80445dd4103103ebaa356c89b
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Feb 25 18:48:10 2011 +0100
Add new radixsort and sradixsort functions
Taken from FreeBSD.
Makefile | 3 +
Versions | 2 +
include/bsd/stdlib.h | 4 +
src/radixsort.3 | 160 +++++++++++++++++++++++++
src/radixsort.c | 327 +++++++++++++++++++++++++++++++++++++++++++++++++++
src/sradixsort.3 | 1 +
6 files changed, 497 insertions(+)
commit c766e58acf3a894644291d21f9c98d322ef8cd11
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Feb 25 18:25:17 2011 +0100
Add man pages for heapsort and mergesort
Taken from FreeBSD, originally as qsort.3 but qsort references stripped.
Makefile | 2 +
src/heapsort.3 | 207 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
src/mergesort.3 | 1 +
3 files changed, 210 insertions(+)
commit be6ab549869d5d6e0ab52eac52537963fa6f71c4
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Feb 25 18:17:16 2011 +0100
Add new mergesort function
Taken from FreeBSD.
Makefile | 1 +
Versions | 2 +
include/bsd/stdlib.h | 4 +-
src/merge.c | 351 +++++++++++++++++++++++++++++++++++++++++++++++++++
4 files changed, 357 insertions(+), 1 deletion(-)
commit 5b19adfa82b49bdb9b46c857b618c181f238290b
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Dec 17 10:50:56 2010 +0100
Add getpeereid function
Makefile | 2 +
Versions | 1 +
include/bsd/unistd.h | 2 +
src/getpeereid.3 | 138 +++++++++++++++++++++++++++++++++++++++++++++++++++
src/getpeereid.c | 132 ++++++++++++++++++++++++++++++++++++++++++++++++
5 files changed, 275 insertions(+)
commit acb7c42d7c394acf9a59c14e5aaf4f43be309acb
Author: Aurelien Jarno <aurelien@aurel32.net>
Date: Fri Jul 30 08:00:41 2010 +0200
Add reallocf function
Makefile | 2 +
Versions | 4 ++
include/bsd/stdlib.h | 2 +
src/reallocf.3 | 107 +++++++++++++++++++++++++++++++++++++++++++++++++++
src/reallocf.c | 48 +++++++++++++++++++++++
5 files changed, 163 insertions(+)
commit 06a60a166ab19000b024dc1f70880278c09d8bc3
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jan 31 14:13:24 2010 +0100
build: Use proper user variables during build
To compile we need to use CPPFLAGS and CFLAGS, to link CFLAGS and
LDFLAGS. Rename MK_CFLAGS to MK_CPPFLAGS as those are only relevant
at compilation time.
Reported-by: Eric Smith <eric@brouhaha.com>
Makefile | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
commit 51863b6cf92883b6f2d58aa764b107e15d834b6f
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jan 30 22:43:29 2010 +0100
build: Use new AR variable instead of hardcoded command
Makefile | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
commit 08afd5d4c9a8579edabc5539e7404677a4f3df71
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jan 30 22:42:00 2010 +0100
build: Refactor COMPILER and LINK commands into new variables
Makefile | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
commit 1f0b0b23cd0a215c575a4becf686e5e005732848
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jan 30 22:40:01 2010 +0100
build: Use CCLD instead of hardcoded gcc for linking
Makefile | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
commit 32d79b0310b6602e4846a5972bebde6b169945f3
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jan 30 22:39:18 2010 +0100
build: By default set CC to gcc
Makefile | 2 ++
1 file changed, 2 insertions(+)
commit cd730a02c36397e4b962271fa6d9119dc820dd4d
Author: Eric Smith <eric@brouhaha.com>
Date: Sat Jan 30 22:13:18 2010 +0100
build: Install shared library with 755 permission
The Makefile should install the shared library with 755 permission
rather than 644. That's standard practice, and required when building
RPMs on Fedora to get a debuginfo package.
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 11f2c32df2722a758f150fb3242d208904ffdacb
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jan 30 22:00:18 2010 +0100
Fix setprogname to strip leading paths from progname
src/progname.c | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
commit 30c794083f5211ecf82f5c3614f35a16a7e4d354
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu Jan 21 14:34:55 2010 +0100
Make setprogname and getprogname arguments and return value const
This is more correct as the strings are not going to be changed, and it
matches the function signatures on other BSDs.
Suggested-by: Aurelien Jarno <aurel32@debian.org>
include/bsd/stdlib.h | 6 +++---
src/progname.c | 9 +++++----
2 files changed, 8 insertions(+), 7 deletions(-)
commit ddebbd6792e5c7ae53fb96cdc46566fc843adaa5
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jan 10 12:04:03 2010 +0100
Release libbsd 0.2.0
Makefile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit abe0a4a7e6e0c8d9c7b8bdb55ade9535ec342578
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jan 10 11:02:13 2010 +0100
Reformat code to KNF
src/bsd_getopt.c | 13 ++++++-------
src/err.c | 46 ++++++++++++++++++++++++----------------------
src/fgetln.c | 2 +-
src/progname.c | 8 ++++----
4 files changed, 35 insertions(+), 34 deletions(-)
commit 2872bfa15193c0b45bf7c212879533b96a8cc2fd
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jan 10 01:41:27 2010 +0100
Add vis and unvis man pages
Taken from OpenBSD.
Makefile | 2 +
src/unvis.3 | 198 +++++++++++++++++++++++++++++++++++++
src/vis.3 | 321 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 521 insertions(+)
commit e544a41f62b223cb03c417d7b250557dbec58a3f
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jan 10 01:37:18 2010 +0100
Add dehumanize_number man page link
Makefile | 1 +
src/dehumanize_number.3 | 1 +
2 files changed, 2 insertions(+)
commit 7b3873bc1e80b9ddb3505b56735c713917b25945
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jan 10 01:35:27 2010 +0100
Update vis and unvis modules from OpenBSD
src/unvis.c | 7 ++++---
src/vis.c | 17 ++++-------------
2 files changed, 8 insertions(+), 16 deletions(-)
commit 8103fe1486cdb95e4d985194cac79bc5940e82ce
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jan 10 01:33:07 2010 +0100
Update strlcat and strlcpy from OpenBSD
src/strlcat.c | 43 ++++++++++++-------------------------------
src/strlcpy.3 | 52 +++++++++++++++++++---------------------------------
src/strlcpy.c | 52 +++++++++++++++++-----------------------------------
3 files changed, 48 insertions(+), 99 deletions(-)
commit d63e081303521c45baeaabd002c706196c51048e
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jan 10 00:57:07 2010 +0100
Add arc4random_buf and arc4random_uniform functions
Update arc4random module from FreeBSD.
Makefile | 2 +
Versions | 3 +
src/arc4random.3 | 28 ++++++-
src/arc4random.c | 195 +++++++++++++++++++++++++++++++++--------------
src/arc4random_buf.3 | 1 +
src/arc4random_uniform.3 | 1 +
6 files changed, 167 insertions(+), 63 deletions(-)
commit 3fed78e5b08f78256e533788b4bcd6502b0949d7
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jan 10 00:37:03 2010 +0100
Replace setproctitle dummy macro with a function stub
This way we can replace it later on with a real implementation so that
applications can immediately benefit from it w/o the need to recompile
them.
Makefile | 1 +
Versions | 2 ++
include/bsd/sys/cdefs.h | 4 ----
include/bsd/unistd.h | 2 ++
include/bsd/unistd.h => src/setproctitle.c | 23 +++++++----------------
5 files changed, 12 insertions(+), 20 deletions(-)
commit 2a81893cc028b40f7832bf033821a1aacfaaea68
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jan 10 00:10:21 2010 +0100
Add pidfile functions
Taken from FreeBSD.
Remove MAXPATHLEN from ‘struct pidfh’ and allocate pf_path dynamically,
as some systems do not have such limits. Use dev_t instead of __dev_t.
Replace EDOOFUS with EINVAL.
Makefile | 2 +
Versions | 5 ++
include/libutil.h | 12 +++
src/pidfile.3 | 254 +++++++++++++++++++++++++++++++++++++++++++++++++++++
src/pidfile.c | 255 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
5 files changed, 528 insertions(+)
commit 98a2479f0ba02a0c54ff360aa5745ff5a6939b2e
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jan 9 23:49:32 2010 +0100
Add flopen function
Taken from FreeBSD.
Makefile | 2 ++
Versions | 2 ++
include/libutil.h | 2 ++
src/flopen.3 | 102 ++++++++++++++++++++++++++++++++++++++++++++++++++++
src/flopen.c | 105 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
5 files changed, 213 insertions(+)
commit 57cc5326cf75826c5d3b415673e2574384d12850
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jan 9 20:17:16 2010 +0100
Move man pages to the same directory as the source code
This matches BSD style source tree, and makes it easier to see what's
missing.
Makefile | 6 +++---
{man => src}/.gitignore | 0
{man => src}/arc4random.3 | 0
{man => src}/arc4random_addrandom.3 | 0
{man => src}/arc4random_stir.3 | 0
{man => src}/fgetln.3 | 0
{man => src}/fmtcheck.3 | 0
{man => src}/getmode.3 | 0
{man => src}/humanize_number.3 | 0
{man => src}/mdX.3 | 0
{man => src}/nlist.3 | 0
{man => src}/readpassphrase.3 | 0
{man => src}/setmode.3 | 0
{man => src}/strlcat.3 | 0
{man => src}/strlcpy.3 | 0
{man => src}/strmode.3 | 0
{man => src}/strtonum.3 | 0
17 files changed, 3 insertions(+), 3 deletions(-)
commit 9e4adc4633b321bf4f3f41feeac7597162cf88f9
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Dec 13 01:52:03 2009 +0100
build: Untangle the package version from the soversion
Add a new script to generate the package version from git. Use that for
the pkg-config file and the tarball name.
Makefile | 7 +++++--
get-version | 48 ++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 53 insertions(+), 2 deletions(-)
commit db406fe24ce18ddce4aa0c5985a77233347d3f27
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Dec 12 01:46:25 2009 +0100
build: Make dist use files from git plus few autogenerated ones
To avoid forgetting to include files, we'll use “git ls-files” and will
include few precious autogenerated files that cannot be generated later
on w/o git. This includes mainly the ChangeLog.
Makefile | 10 +++-------
1 file changed, 3 insertions(+), 7 deletions(-)
commit 9396cc62cf01f282feef7ef9f212f73691100d04
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jan 9 19:56:45 2010 +0100
build: Do not duplicate generated filenames in several variables
Makefile | 19 +++++++++++--------
1 file changed, 11 insertions(+), 8 deletions(-)
commit 7a70f1b019a64902a3c8a722ee5287d72a1cbf5b
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Dec 11 23:24:31 2009 +0100
Move fmtcheck and fgetln declarations to <bsd/stdio.h>
This is were they are located on the BSDs.
Makefile | 1 +
include/bsd/{string.h => stdio.h} | 10 ++++------
include/bsd/stdlib.h | 5 ++---
include/bsd/string.h | 6 +++---
4 files changed, 10 insertions(+), 12 deletions(-)
commit ca28f28046b2cc4beb38cb4b63c75f0ac6379bcd
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Dec 11 23:21:14 2009 +0100
Move setmode and getmode declarations to <bsd/unistd.h>
This is were they are located on the BSDs.
Makefile | 1 +
include/bsd/stdlib.h | 10 +++-------
include/bsd/{stdlib.h => unistd.h} | 29 +++--------------------------
3 files changed, 7 insertions(+), 33 deletions(-)
commit dd2756e000208ee9e4cde3373f217fc7c98f0610
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Dec 11 23:13:42 2009 +0100
Mark inclusion of <time.h> from <bsd/bsd.h> deprecated
This will be removed at some point in the future.
include/bsd/bsd.h | 2 ++
1 file changed, 2 insertions(+)
commit 3c9182b85e785159b349106c04ccc1b4ec045350
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Dec 11 23:12:26 2009 +0100
Move arc4random declarations to <bsd/stdlib.h>
This is were they are located on the BSDs.
include/bsd/bsd.h | 1 -
include/bsd/random.h | 9 ++-------
include/bsd/stdlib.h | 4 ++++
3 files changed, 6 insertions(+), 8 deletions(-)
commit 4d17a18db559a3e3485d049cddf808090f38e8be
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Dec 11 23:06:27 2009 +0100
Deprecate <bsd/inet.h>
The only function declared in that header file was inet_net_pton, which
is already provided by glibc. Will be removed on the next SONAME bump.
Versions | 3 ++-
include/bsd/inet.h | 7 ++-----
2 files changed, 4 insertions(+), 6 deletions(-)
commit 7da57b293f96d0c52e5b76b539e934db49323ee2
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Dec 11 23:01:02 2009 +0100
Remove traces of fgetwln, it was never included
This function was exposed in the header file and the versioning symbol
file, but the actual code was never here.
Versions | 1 -
include/bsd/string.h | 2 --
2 files changed, 3 deletions(-)
commit 254808d9ef26c5910f981f8119af62db3d7fd72e
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Dec 11 23:26:44 2009 +0100
Define NetBSD version 5.0 for .Nx to avoid groff warning
This is a temporary workaround, the proper fix is to get groff to know
newest BSD versions.
man/humanize_number.3 | 2 ++
1 file changed, 2 insertions(+)
commit 183cc3cbf1c42eedbde8cf18da52ec0004b9049f
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Dec 11 21:31:48 2009 +0100
Correct library name in man pages
man/arc4random.3 | 3 ++-
man/fgetln.3 | 3 ++-
man/fmtcheck.3 | 3 ++-
man/humanize_number.3 | 3 +++
man/mdX.3 | 3 +++
man/nlist.3 | 3 ++-
man/readpassphrase.3 | 3 +++
man/setmode.3 | 3 ++-
man/strlcpy.3 | 3 ++-
man/strmode.3 | 3 ++-
man/strtonum.3 | 3 +++
11 files changed, 26 insertions(+), 7 deletions(-)
commit c17c7e13c3522c6d72ceb4bc207308b8c7452b44
Author: Thorsten Glaser <tg@mirbsd.org>
Date: Thu Dec 10 18:07:25 2009 +0100
Expand on API guarantee for fgetln
OpenBSD has begun using the API guarantee that *len is not 0 if
the fgetln(3) return value is not NULL; document this explicitly
in the manpage and add a comment to the function implementation
that this doesn’t need to be checked because getdelim/getline have
similar guarantees.
Signed-off-by: Thorsten Glaser <tg@mirbsd.org>
man/fgetln.3 | 2 +-
src/fgetln.c | 1 +
2 files changed, 2 insertions(+), 1 deletion(-)
commit a5dbef45e77f1de47b11669443ece451e90b85ab
Author: Thorsten Glaser <tg@mirbsd.org>
Date: Thu Dec 10 21:02:30 2009 +0100
Make RCS macros take arguments
This was breaking code actually using those macros.
Signed-off-by: Thorsten Glaser <tg@mirbsd.org>
include/bsd/sys/cdefs.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
commit 27842d7f773557031790f9479a417ba7c2110e96
Author: Thorsten Glaser <tg@mirbsd.org>
Date: Thu Dec 10 21:00:45 2009 +0100
Track bug IDs for __unused collision
Signed-off-by: Thorsten Glaser <tg@mirbsd.org>
include/bsd/sys/cdefs.h | 1 +
1 file changed, 1 insertion(+)
commit c5398adfe22819f336eb637568050748d0227cad
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Oct 24 00:19:47 2009 +0200
Add readpassphrase function
Taken from OpenBSD.
Makefile | 3 +
Versions | 2 +
include/bsd/readpassphrase.h | 41 ++++++++++
man/readpassphrase.3 | 165 ++++++++++++++++++++++++++++++++++++++
src/readpassphrase.c | 187 +++++++++++++++++++++++++++++++++++++++++++
5 files changed, 398 insertions(+)
commit 538bc87998624377ba72589a0ee68e4527f82489
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Oct 24 00:17:57 2009 +0200
Add dehumanize_number function
Taken from NetBSD.
Makefile | 1 +
Versions | 2 +
include/bsd/stdlib.h | 6 +++
src/dehumanize_number.c | 114 ++++++++++++++++++++++++++++++++++++++++++++++++
4 files changed, 123 insertions(+)
commit 04250f6a7c3e2d22a9861b82615329e1dc328c93
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Oct 24 00:15:57 2009 +0200
Add strnvis and strnunvis functions
Taken from OpenBSD.
Versions | 3 +++
include/vis.h | 2 ++
src/unvis.c | 41 +++++++++++++++++++++++++++++++++++++++
src/vis.c | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++--
4 files changed, 105 insertions(+), 2 deletions(-)
commit 5c078ce2f581e1bdfc918326051c587e0cb1d0d6
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Oct 23 23:31:07 2009 +0200
Move <bsd/ip_icmp.h> to <bsd/netinet/ip_icmp.h>
This maps more closely the location of the real header. For
transitional purposes keep a <bsd/ip_icmp.h> that warns and includes
<bsd/netinet/ip_icmp.h>.
Makefile | 4 +-
include/bsd/bsd.h | 2 +-
include/bsd/ip_icmp.h | 202 +++---------------------------------
include/bsd/{ => netinet}/ip_icmp.h | 0
4 files changed, 21 insertions(+), 187 deletions(-)
commit 614eb0402a2f8f6f16da9e293aa3c5203143fd38
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Oct 12 01:43:02 2009 +0200
Add new <bsd/sys/tree.h> header
Makefile | 1 +
include/bsd/bsd.h | 1 +
include/bsd/sys/tree.h | 765 +++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 767 insertions(+)
commit b6e8469059c447c17cd84e59dbe5d51cd178376f
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Oct 12 01:47:54 2009 +0200
Move <bsd/queue.h> to <bsd/sys/queue.h>
This maps more closely the location of the real header. For
transitional purposes keep a <bsd/queue.h> that warns and includes
<bsd/sys/queue.h>.
Makefile | 3 +-
include/bsd/bsd.h | 2 +-
include/bsd/queue.h | 625 ++----------------------------------------
include/bsd/{ => sys}/queue.h | 0
4 files changed, 22 insertions(+), 608 deletions(-)
commit d3e14ea99e39a2916928afc50a7cf29e152dcb75
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Oct 23 23:04:42 2009 +0200
Move <bsd/cdefs.h> to <bsd/sys/cdefs.h>
This maps more closely the location of the real header. For
transitional purposes keep a <bsd/cdefs.h> that warns and includes
<bsd/sys/cdefs.h>.
Makefile | 4 ++-
include/bsd/bsd.h | 2 +-
include/bsd/cdefs.h | 67 ++++---------------------------------------
include/bsd/{ => sys}/cdefs.h | 0
4 files changed, 9 insertions(+), 64 deletions(-)
commit e51be45c4086dcf9e533899cf2ca4e9250773a2d
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Oct 12 01:43:52 2009 +0200
Update <sys/queue.h>
Taken from FreeBSD.
include/bsd/queue.h | 191 +++++++++++++++++++++++++++++++++++-----------------
1 file changed, 130 insertions(+), 61 deletions(-)
commit 56ddcfe65ac1526fe9c048c50f836cedd434dbac
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Oct 11 21:07:53 2009 +0200
Add strtonum function
Taken from FreeBSD.
Makefile | 2 +
Versions | 4 ++
include/bsd/stdlib.h | 3 +
man/strtonum.3 | 156 +++++++++++++++++++++++++++++++++++++++++++++++++++
src/strtonum.c | 68 ++++++++++++++++++++++
5 files changed, 233 insertions(+)
commit 1bf8b96ac8fd99a4764ef13f5234853a943f3140
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Oct 24 01:06:09 2009 +0200
Do not append a slash after DESTDIR
Makefile | 26 +++++++++++++-------------
1 file changed, 13 insertions(+), 13 deletions(-)
commit 16e6ac99fefbb297299e7e4c876c860d11a4b5b8
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Oct 11 20:54:23 2009 +0200
Update git web interface URL
FreeDesktop.Org switched from gitweb to cgit.
README | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 56f2e55b7afd257b56773048129093fce19c1a62
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Aug 30 12:18:11 2009 +0200
Release libbsd 0.1.6
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 5ac14531b5ffc9e9ea5c890a21e562bf664e0504
Author: Hirokazu Takata <takata@linux-m32r.org>
Date: Sun Aug 30 12:16:01 2009 +0200
Fix typos in M32R local-elf.h endian definitions
src/local-elf.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 2543c5a78bc84eca4af52d11b808dc848601e501
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jul 17 13:37:38 2009 +0200
Release libbsd 0.1.5
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 33ef70b9e170536115a4139df2c53f6af935418f
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jul 17 13:35:37 2009 +0200
Add __pure2 dummy macro
include/bsd/cdefs.h | 4 ++++
1 file changed, 4 insertions(+)
commit 8ef0ecdf4431b84d9419d89f9460a38a24be19d7
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jul 17 13:34:30 2009 +0200
Add more dummy id macros
include/bsd/cdefs.h | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
commit 6660397589657e95cfa67cf045814795fd4a043a
Author: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
Date: Fri Jul 17 12:50:07 2009 +0200
Fix typos in AVR32 and SH local-elf.h endian definitions
src/local-elf.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 391c75b4270a6bde57b316e557d3ae6eec017969
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 29 02:48:00 2009 +0200
Release libbsd 0.1.4
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 45783ae4ca20b0b55f549785e5f63209750b60ed
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 29 02:45:54 2009 +0200
Define N_SYMSIZE in case the system does not do it
Fixes build failures on some non-Linux ports.
Based-on-patch-by: Petr Salinger <Petr.Salinger@seznam.cz>
src/nlist.c | 3 +++
1 file changed, 3 insertions(+)
commit 5902730a03a2df02a0ad71c62ce83046fc6c2bb8
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 29 02:28:49 2009 +0200
Create a relative symlink for .so if libdir and usrlibdir are the same
Makefile | 6 ++++++
1 file changed, 6 insertions(+)
commit 42601170ace98fe62c1f63a4d1b820a0bacf3e1a
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 25 10:02:26 2009 +0200
Change @libdir@ in the pkg-config file to be $(usrlibdir)
The variable in the .pc file points to the directory where the .so
symlink is present, which is never going to be something like /lib,
but something like /usr/lib.
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 0bd48c4a4d5382fd4d1e71b63b0d875637765dc1
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 25 09:57:14 2009 +0200
Preserve the variables unexpanded in the pkg-config file
Makefile | 23 +++++++++++------------
1 file changed, 11 insertions(+), 12 deletions(-)
commit d03b2b07fc7f8084e8f56b69dc65a11c74caf5b7
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 25 09:37:39 2009 +0200
Release libbsd 0.1.3
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit cb1346e5b3bdeb98e4118053e2520ae68d2111b1
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 25 09:25:13 2009 +0200
Export public functions as extern C
include/bsd/err.h | 4 ++++
include/bsd/getopt.h | 4 ++++
include/bsd/inet.h | 5 ++++-
include/bsd/random.h | 5 ++++-
include/bsd/stdlib.h | 5 ++++-
include/bsd/string.h | 3 +++
6 files changed, 23 insertions(+), 3 deletions(-)
commit 61fa98ea9e288abb4aa5b12be8fed9f73e2a1a9c
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 25 09:12:45 2009 +0200
Add missing <stdarg.h> include in <bsd/err.h>
include/bsd/err.h | 1 +
1 file changed, 1 insertion(+)
commit 931e04343038cfc543f6d931488e597c9bee2d7e
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 25 08:56:34 2009 +0200
Add new __RCSID macro
Define it to nothing, so that source imported from BSDs can be easily
compiled w/o needing to modify them.
include/bsd/cdefs.h | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
commit f984a7006bd8b456d4ea8aebc717e4e758676d7c
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 25 06:57:50 2009 +0200
Release libbsd 0.1.2
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 326a3a76193161f096990a073d97d288f73f3408
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 25 06:57:03 2009 +0200
Install humanize_number(3) man page
Makefile | 1 +
1 file changed, 1 insertion(+)
commit e4aff3d9fc9e22287cfeab040e4b968d53a9255e
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 25 06:41:42 2009 +0200
Use N_SYMSIZE instead of directly accessing ‘struct exec’
On Linux alpha ‘struct exec’ does not have an a_syms member, and the
N_SYMSIZE is mapped to 0.
src/nlist.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit c3feeb0092ace00f95aa981fc907ab654afaa5f7
Author: Gerardo Exequiel Pozzi <vmlinuz386@yahoo.com.ar>
Date: Fri May 22 20:44:35 2009 -0300
Add some man page links
Add man page links for strlcat, getmode and arc4random_*.
Signed-off-by: Gerardo Exequiel Pozzi <vmlinuz386@yahoo.com.ar>
Makefile | 4 ++++
man/arc4random_addrandom.3 | 1 +
man/arc4random_stir.3 | 1 +
man/getmode.3 | 1 +
man/strlcat.3 | 1 +
5 files changed, 8 insertions(+)
commit 80c3954e3cf66efa907b8a8862632f56eeea9543
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 25 06:23:01 2009 +0200
Use the correct path when including a.out.h
Reported-by: Aurélien Jarno <aurelien@aurel32.net>
include/nlist.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 4c3e03efebe725b22fe52a981235314ae6ee4218
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon May 25 06:22:22 2009 +0200
Add man/md5.3bsd to .gitignore
man/.gitignore | 1 +
1 file changed, 1 insertion(+)
commit 9b30dae90952053dd0be1740d0a6f494c638b8dd
Author: Guillem Jover <guillem@hadrons.org>
Date: Thu May 21 05:04:09 2009 +0200
Fix typos (‘ELFDATA2MSG’ → ‘ELFDATA2MSB’)
src/local-elf.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
commit 25dd60b9cc5f0a5ae867f9e7215cda7c28e89562
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed May 20 05:14:32 2009 +0200
Release libbsd 0.1.1
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 5b16707e95d89d6a6b485bf3b26d4d340e2d9c6a
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed May 20 05:13:31 2009 +0200
Install nlist header and man page
Makefile | 2 ++
1 file changed, 2 insertions(+)
commit 1f0b016e97611a35151eca4952277211a0ee4656
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed May 20 04:20:21 2009 +0200
Use UTF-8 copyright symbols for non-imported files
include/bsd/bsd.h | 2 +-
include/bsd/cdefs.h | 2 +-
include/bsd/err.h | 2 +-
include/bsd/getopt.h | 2 +-
include/bsd/inet.h | 2 +-
include/bsd/random.h | 2 +-
include/bsd/stdlib.h | 6 +++---
include/bsd/string.h | 2 +-
include/nlist.h | 2 +-
src/bsd_getopt.c | 2 +-
src/err.c | 2 +-
src/fgetln.c | 4 ++--
src/local-elf.h | 2 +-
src/progname.c | 2 +-
14 files changed, 17 insertions(+), 17 deletions(-)
commit dcaec44a6fd4ede2b8d8050a7c05185c28f66917
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed May 20 04:11:57 2009 +0200
Add nlist function
Makefile | 1 +
Versions | 3 +
include/nlist.h | 38 +++++
man/nlist.3 | 77 +++++++++++
src/local-elf.h | 197 ++++++++++++++++++++++++++
src/nlist.c | 419 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
6 files changed, 735 insertions(+)
commit 8dbfb3529b0253ba8067042dabaebe3ad89cb039
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 15 21:40:45 2009 +0200
Add strmode function
Makefile | 6 ++-
Versions | 5 ++
include/bsd/string.h | 4 +-
man/strmode.3 | 144 +++++++++++++++++++++++++++++++++++++++++++++++++
src/strmode.c | 149 +++++++++++++++++++++++++++++++++++++++++++++++++++
5 files changed, 305 insertions(+), 3 deletions(-)
commit 74ae34e792a08de78ab671a683abdf48c27eccd3
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 15 21:26:09 2009 +0200
Fix buffer leaks in fgetln
Cache the size and the buffer allocated by getline as static variables.
src/fgetln.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit deb9f56ceb560f96448ff9bfa1befdf7ed9849de
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri May 15 21:23:03 2009 +0200
Change fgetln to return the correct length value
Set len to 0 on error conditions to mimmic FreeBSD behaviour, and return
the amount of read characters on success, instead of the allocated size
by getline.
Reported-by: Jief L. <jief1.l@gmail.com>
src/fgetln.c | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
commit aefc6f441aa1ae51135fea33d25572e39222cce7
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 26 22:42:39 2008 +0300
Do not include .gitignore in the dist tarball
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit f2d93325e6d073681c55f6959bed3a172bc15989
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 26 22:39:29 2008 +0300
Install md5.3 as md5.3bsd
This man page is pretty common in other source projects, so we use a
suffix to distinguish it.
Makefile | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
commit 5e1a78211983e2547838ce3fd2dd607e0a320393
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 26 22:36:14 2008 +0300
Add a TODO list
TODO | 4 ++++
1 file changed, 4 insertions(+)
commit 4c9c8ed74c946338310a46cc41122b904d0b934d
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 26 22:35:31 2008 +0300
Add a new header file to expose inet_net_pton prototype
Makefile | 1 +
include/bsd/inet.h | 35 +++++++++++++++++++++++++++++++++++
2 files changed, 36 insertions(+)
commit 6dc84320cc267b5ed6c2e1de9e4b9d49e465dc54
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 26 22:25:22 2008 +0300
Add a micro version part
Makefile | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
commit acc23243fb450adb18f4c0a2b28bbf9ebae11053
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 08:00:17 2008 +0300
Unify description
libbsd.pc.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 9a2b946fce5c6606f45c4f7627645701448d39f4
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 07:59:14 2008 +0300
Move LIB_PKGCONFIG dependency to the libs target
Makefile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit ad52f2eb4c5d8370298de587f090e84727d8bcf2
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 07:55:57 2008 +0300
Use sigprocmask instead of _sigprocmask
src/setmode.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 2729ca824d2c277bd1e32cebfe43739996705087
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 07:53:03 2008 +0300
Define default CFLAGS overridable by the environment
Makefile | 3 +++
1 file changed, 3 insertions(+)
commit 83210a83a4a13115ce653ec5f1419279a63191f7
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 07:48:10 2008 +0300
Switch remaining variables to single expanded ones
Makefile | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
commit 69c94c50d98e3aa6ffbaaa9d29e5c257adc58865
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 07:46:53 2008 +0300
Remove useless comment header
Makefile | 4 ----
1 file changed, 4 deletions(-)
commit 2d5c088a173913a01daa3f5042d9fa6f245d958c
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 07:46:37 2008 +0300
Move each groups of related files to their own line
Makefile | 53 ++++++++++++++++++++++++++++++++++++++++++-----------
1 file changed, 42 insertions(+), 11 deletions(-)
commit 3de930e682026512f7333194abcefdeb621e6adc
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 07:41:07 2008 +0300
Make action targets PHONY
Makefile | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
commit e9cb0d1cf4556db22b755a1fa34c9c219b78d2f0
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 07:37:13 2008 +0300
New README file
Makefile | 2 +-
README | 32 ++++++++++++++++++++++++++++++++
2 files changed, 33 insertions(+), 1 deletion(-)
commit 87d6d656335858cd0768aa5dd30b4d0d5967bd10
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 07:31:59 2008 +0300
Automatically generate libbsd.pc from libbsd.pc.in
.gitignore | 1 +
Makefile | 14 ++++++++++++--
libbsd.pc => libbsd.pc.in | 10 +++++-----
3 files changed, 18 insertions(+), 7 deletions(-)
commit ff8539bc035800ff551174b99bb17da27890b660
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 07:29:24 2008 +0300
Add new path variables
Makefile | 33 ++++++++++++++++++++++-----------
1 file changed, 22 insertions(+), 11 deletions(-)
commit 8c7f053ab0d9a3f54a38b752ffbcc2c6ef226f8c
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 07:00:19 2008 +0300
Automatically generate the ChangeLog on 'make dist'
.gitignore | 1 +
Makefile | 9 +++++++--
2 files changed, 8 insertions(+), 2 deletions(-)
commit c1615a50d35da13c174a9e162995de7fcb024773
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 06:46:18 2008 +0300
Define a LIB_PKGCONFIG variable
Makefile | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
commit e42791d0d3e09848da10e2062f5e32d8b52effc7
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 06:41:10 2008 +0300
Move filename related variables to the beginning of the file
Switch them to single expanded varibles.
Makefile | 11 +++++------
1 file changed, 5 insertions(+), 6 deletions(-)
commit 1e1ab1875895b432966686402ac3debd2b384256
Author: Guillem Jover <guillem@hadrons.org>
Date: Sat Jul 12 06:35:45 2008 +0300
Define a LIB_VERSION variable
Makefile | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
commit ba7ece7791d2617de8693a877b517260c51f5dc7
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 9 09:25:34 2008 +0300
Create an armored detached signature on 'make dist'
Makefile | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
commit 84d311d03872a1c18305abe8218c0a3d3f5434d2
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 9 09:07:58 2008 +0300
Remove link_addr and link_ntoa symbols from the version script
Versions | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 38829bdc8b5dd17d8d10a2daf350605e7c6f70a4
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 9 09:07:03 2008 +0300
Add new setmode and getmode functions from FreeBSD
Makefile | 3 +-
Versions | 4 +
include/bsd/stdlib.h | 9 ++
man/setmode.3 | 114 +++++++++++++
src/setmode.c | 444 +++++++++++++++++++++++++++++++++++++++++++++++++++
5 files changed, 573 insertions(+), 1 deletion(-)
commit a5f7d1a8f12b0ce3b76a23dccb8a5ffdc31ebf39
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 9 09:04:51 2008 +0300
Include the rest of the header files
include/bsd/bsd.h | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
commit 8b95dc5865f26d746651479fd893e77e1f594b56
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 9 09:04:27 2008 +0300
Disable __bounded__ __attribute__
include/bsd/cdefs.h | 4 ++++
1 file changed, 4 insertions(+)
commit 96358a2ad649ec2520357470abe3ae86837bf68b
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 9 08:47:09 2008 +0300
Add support for 'make dist'
Makefile | 10 ++++++++++
1 file changed, 10 insertions(+)
commit fafffd1f7eebdf73a5e3ceb343025272493ebf21
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 9 08:26:07 2008 +0300
fgetln: Fix coding style
src/fgetln.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
commit 47109e39d5995c7addaa932625fb0ea1e0e8200a
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 9 08:22:30 2008 +0300
fgetln: Fix function to make it actually work
Reported by Thorsten Glaser.
src/fgetln.c | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
commit da92787d48723ef900d3976072f37960d7a96d8b
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 9 07:46:23 2008 +0300
Ansify function arguments
src/fgetln.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
commit fc163cee2fd148ef121e2481dfc08065b36b6b2b
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 9 07:23:49 2008 +0300
Move version and library name to the beginning of the file
Makefile | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
commit 1512d0d4ab508d47aff2d301d90317c11dd50846
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 9 07:22:30 2008 +0300
Renumber 4th clause from BSD license to 3rd
Those files have only three clauses.
include/bsd/ip_icmp.h | 2 +-
include/bsd/queue.h | 2 +-
include/vis.h | 2 +-
man/fgetln.3 | 2 +-
src/heapsort.c | 2 +-
src/unvis.c | 2 +-
src/vis.c | 2 +-
7 files changed, 7 insertions(+), 7 deletions(-)
commit 7b1c361f4d09522b5af9398814f2e809f42d7b9b
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 9 07:17:20 2008 +0300
Remove RCS tag
Makefile | 2 --
1 file changed, 2 deletions(-)
commit b0f64624bb41ccc00d80f218acb0d2758dd8d5d3
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jul 9 07:16:20 2008 +0300
Add missing license headers
With permission from Robert Millan and Aurelien Jarno.
include/bsd/err.h | 26 ++++++++++++++++++++++++++
include/bsd/getopt.h | 26 ++++++++++++++++++++++++++
include/bsd/stdlib.h | 27 +++++++++++++++++++++++++++
3 files changed, 79 insertions(+)
commit efa9658ba60be9a48f7a750a6b93932462757a97
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 18 08:51:53 2008 +0300
Remove link_addr and link_ntoa functions
The address familiy used is kernel dependent, so the application will
have to be ported regardless.
Makefile | 4 +-
src/linkaddr.c | 156 ---------------------------------------------------------
2 files changed, 2 insertions(+), 158 deletions(-)
commit a5709cbc88543a894fcb12da181b33e7ccc68a7b
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 18 08:47:58 2008 +0300
Add license header
include/libutil.h | 38 ++++++++++++++++++++++++++++++++++++++
1 file changed, 38 insertions(+)
commit bf4eeb29f049e374b33b788a8df02357d659183c
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 18 08:44:18 2008 +0300
Add arc4random_stir and arc4random_addrandom functions
Makefile | 2 +-
Versions | 2 ++
include/bsd/random.h | 2 ++
src/arc4random.c | 28 ++++++++++++++++++++++++++++
4 files changed, 33 insertions(+), 1 deletion(-)
commit 26ab4750eebff515ca5717ee272a79fa3866ab55
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 18 08:25:48 2008 +0300
Add a pkg-config file
Makefile | 2 ++
libbsd.pc | 11 +++++++++++
2 files changed, 13 insertions(+)
commit b37f1039efda597cf821be7be88b280aaf14c2b9
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 18 08:19:41 2008 +0300
Replace current md5 code with one from MirBSD and OpenBSD
This adds the following public functions:
MD5Transform, MD5End, MD5File, MD5FileChunk, MD5Data
Makefile | 20 +++-
Versions | 6 +
include/bsd/md5.h | 77 ++++++------
man/.gitignore | 1 +
man/mdX.3 | 223 ++++++++++++++++++++++++++++++++++
src/hash/.gitignore | 1 +
src/hash/helper.c | 100 ++++++++++++++++
src/hash/md5.c | 248 ++++++++++++++++++++++++++++++++++++++
src/md5.copyright | 21 ----
src/md5c.c | 338 ----------------------------------------------------
10 files changed, 636 insertions(+), 399 deletions(-)
commit 20bf55ffa5a56d3ee062aa199e5b3033ea29c52a
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 18 08:09:51 2008 +0300
Include missing stddef.h
include/bsd/string.h | 1 +
1 file changed, 1 insertion(+)
commit d699e4bc0e5196520dcb23e6768d977570de42f8
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 18 08:05:23 2008 +0300
Add license header
With Hector's agreement.
src/fgetln.c | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)
commit 3b51d12e1fd7bbdde21dc2fe3fc720a75cf9d8c7
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 18 08:00:10 2008 +0300
Add a .gitignore file
.gitignore | 4 ++++
1 file changed, 4 insertions(+)
commit d033e58045ab39b159e74d390eda76c3988a06fd
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 18 07:59:43 2008 +0300
Remove cruft macros and includes
include/bsd/bsd.h | 26 --------------------------
1 file changed, 26 deletions(-)
commit c14d23b5d749d8f06fc857003f848f25ee87638f
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Jun 18 07:49:44 2008 +0300
Add license header
include/bsd/bsd.h | 26 ++++++++++++++++++++++++++
include/bsd/cdefs.h | 26 ++++++++++++++++++++++++++
include/bsd/random.h | 26 ++++++++++++++++++++++++++
include/bsd/string.h | 26 ++++++++++++++++++++++++++
4 files changed, 104 insertions(+)
commit d83f5791e9a0b5d4c4004c8406c27ad8cb3134bd
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 13 06:49:03 2008 +0300
Remove ChangeLog file
ChangeLog | 174 --------------------------------------------------------------
1 file changed, 174 deletions(-)
commit acb577d6c150370ea17fe5a07bd1361bfa4d18e2
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 13 05:25:57 2008 +0300
Sync humanize_number from NetBSD
Add the missing man page.
man/humanize_number.3 | 166 ++++++++++++++++++++++++++++++++++++++++++++++++++
src/humanize_number.c | 9 ++-
2 files changed, 173 insertions(+), 2 deletions(-)
commit 0be77c90b57f7c1af8796701aa294258400f1cc4
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Jun 13 05:23:39 2008 +0300
Convert TNF licenses to new 2 clause variant
This follows NetBSD upstream:
<http://mail-index.netbsd.org/source-changes/2008/04/30/msg005553.html>
man/fmtcheck.3 | 7 -------
src/fmtcheck.c | 7 -------
src/humanize_number.c | 7 -------
3 files changed, 21 deletions(-)
commit 8ca3d66d47c1a9685835dd8d91c18289f4c6ed14
Author: Robert Millan <rmh@aybabtu.com>
Date: Sun Mar 16 17:20:48 2008 +0000
Add license header
src/bsd_getopt.c | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)
commit 532aec99b6dccbf02fe9504ba9e852f6da7dbbc0
Author: Robert Millan <rmh@aybabtu.com>
Date: Sun Mar 16 16:49:41 2008 +0000
Relicense err.c and progname.c to avoid trouble with 4-clause BSD code
src/err.c | 41 +++++++++++++++++++++++++----------------
src/progname.c | 41 +++++++++++++++++++++++++----------------
2 files changed, 50 insertions(+), 32 deletions(-)
commit 44706ade0647dc5a77213529ab234a2007eb06e7
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Mar 16 16:46:29 2008 +0000
Remove UC Berkeley advertising clause
As per <ftp://ftp.cs.berkeley.edu/pub/4bsd/README.Impt.License.Change>.
ChangeLog | 1 +
man/fgetln.3 | 4 ----
2 files changed, 1 insertion(+), 4 deletions(-)
commit f5b8317051c54df10b9bb6ce83d82dcb8dc19439
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Mar 16 14:30:51 2008 +0000
Remove UC Berkeley advertising clause
As per <ftp://ftp.cs.berkeley.edu/pub/4bsd/README.Impt.License.Change>.
ChangeLog | 9 +++++++++
include/vis.h | 4 ----
src/heapsort.c | 4 ----
src/linkaddr.c | 4 ----
src/unvis.c | 4 ----
src/vis.c | 4 ----
6 files changed, 9 insertions(+), 20 deletions(-)
commit c5793d47d19a07f42c5b32e1fc4672222e9af8fd
Author: Petr Salinger <Petr.Salinger@seznam.cz>
Date: Tue Dec 18 14:20:20 2007 +0000
bsd/queue.h: Sync with current glibc variant from GNU/kFreeBSD
ChangeLog | 4 ++++
include/bsd/queue.h | 4 ++--
2 files changed, 6 insertions(+), 2 deletions(-)
commit ac32eefec50a1f9a6c4a75b7467731fc99a0a109
Author: Petr Salinger <Petr.Salinger@seznam.cz>
Date: Tue Jan 9 13:26:33 2007 +0000
bsd/bsd.h: Cleanup
include/bsd/bsd.h | 54 +++++-------------------------------------------------
1 file changed, 5 insertions(+), 49 deletions(-)
commit 2ef27385c5a4d757f19a07096bbcc2d0a3e36d85
Author: Aurelien Jarno <aurel32@debian.org>
Date: Tue Nov 7 23:41:16 2006 +0000
link_addr: New function
ChangeLog | 7 +++
Makefile | 4 +-
Versions | 1 +
src/linkaddr.c | 160 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
4 files changed, 170 insertions(+), 2 deletions(-)
commit 30176335f9e09f038c107bbc78eaba8b5c2cd057
Author: Petr Salinger <Petr.Salinger@seznam.cz>
Date: Fri Aug 25 13:39:32 2006 +0000
humanize_number: New function
ChangeLog | 7 +++
Makefile | 5 +-
Versions | 1 +
include/libutil.h | 22 ++++++++
src/humanize_number.c | 145 ++++++++++++++++++++++++++++++++++++++++++++++++++
5 files changed, 178 insertions(+), 2 deletions(-)
commit 326d210f1774a30e309062c3d5819e5868e4ee4b
Author: Robert Millan <rmh@aybabtu.com>
Date: Thu Mar 30 13:53:34 2006 +0000
Revert 1d87476250217a87319df48a8f473415c0515106
src/progname.c | 12 +++---------
1 file changed, 3 insertions(+), 9 deletions(-)
commit 1d87476250217a87319df48a8f473415c0515106
Author: Robert Millan <rmh@aybabtu.com>
Date: Thu Mar 30 11:14:56 2006 +0000
Duplicate setprogname argument
For some reason, accessing the argv vector directly may cause SIGSEV.
src/progname.c | 12 +++++++++---
1 file changed, 9 insertions(+), 3 deletions(-)
commit 3462d1261f2cd9ff26faaf4a0027c661b37af999
Author: Robert Millan <rmh@aybabtu.com>
Date: Wed Mar 29 13:55:22 2006 +0000
Add heapsort
ChangeLog | 7 ++
Makefile | 2 +-
Versions | 1 +
include/bsd/stdlib.h | 2 +
src/heapsort.c | 179 +++++++++++++++++++++++++++++++++++++++++++++++++++
5 files changed, 190 insertions(+), 1 deletion(-)
commit daccb6a8507c6eb35bb08177834ae15150acddab
Author: Aurelien Jarno <aurel32@debian.org>
Date: Sun Mar 26 17:10:13 2006 +0000
Fix some c++isms
src/inet_net_pton.c | 2 +-
src/md5c.c | 6 ++++--
2 files changed, 5 insertions(+), 3 deletions(-)
commit 1e28f3480721c916b89e643c5cdfceaef69ad0f1
Author: Aurelien Jarno <aurel32@debian.org>
Date: Sun Mar 26 17:09:24 2006 +0000
Directly call the function fmtcheck instead of using __weak_reference
src/fmtcheck.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit d493e6cd987a2d0c6b7d1df1c28883f1974260a9
Author: Robert Millan <rmh@aybabtu.com>
Date: Sat Mar 25 20:03:00 2006 +0000
Move shared library to /lib
Needed by binaries in /bin and /sbin.
Makefile | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
commit 37c5b9a2af298b299ca6553f44dbea15f3b7b796
Author: Robert Millan <rmh@aybabtu.com>
Date: Sun Mar 19 11:12:07 2006 +0000
Fix install paths so that /usr/include also works
Makefile | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
commit 40bb012fee0ab5bea95af3e3de49686562ff0dba
Author: Robert Millan <rmh@aybabtu.com>
Date: Sun Mar 19 10:25:49 2006 +0000
Add vis and unvis
ChangeLog | 8 ++
Makefile | 8 +-
Versions | 2 +
include/vis.h | 90 ++++++++++++++++++
src/unvis.c | 291 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
src/vis.c | 199 +++++++++++++++++++++++++++++++++++++++
6 files changed, 594 insertions(+), 4 deletions(-)
commit a84fcb45ef036cb0c7ea6c4933ecccc9e8edeca0
Author: Robert Millan <rmh@aybabtu.com>
Date: Sat Mar 18 12:53:39 2006 +0000
Fix syntax error
src/progname.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit 31461c563abc61807e8fbbacdb70d6e94f79edce
Author: Robert Millan <rmh@aybabtu.com>
Date: Sat Mar 18 09:19:50 2006 +0000
Initialize __progname as NULL
src/progname.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit 5bd834027d4c6b520ee058d753b479e31e6faf26
Author: Robert Millan <rmh@aybabtu.com>
Date: Fri Mar 17 19:55:21 2006 +0000
Add getprogname and setprogname
ChangeLog | 7 +++++++
Makefile | 2 +-
Versions | 1 +
include/bsd/stdlib.h | 7 ++++++-
src/progname.c | 36 ++++++++++++++++++++++++++++++++++++
5 files changed, 51 insertions(+), 2 deletions(-)
commit 1e8b819b4579d85654d46df2c16f3a58e9b6b878
Author: Guillem Jover <guillem@hadrons.org>
Date: Wed Feb 15 20:41:06 2006 +0000
Disable __unused
It conflicts with a struct member in a Linux header.
ChangeLog | 5 +++++
include/bsd/cdefs.h | 4 ++++
2 files changed, 9 insertions(+)
commit 67e48af044abf058167a60b79d4165f0431fac5a
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 14 07:01:21 2006 +0000
Remove unused includes and protect header
ChangeLog | 5 +++++
include/bsd/getopt.h | 6 ++++++
include/bsd/stdlib.h | 3 ---
3 files changed, 11 insertions(+), 3 deletions(-)
commit 8a2e8584d9a46c0bf8ba431098741cee7e548ddc
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 14 06:55:53 2006 +0000
Revert 39db45e45a8d49a92d1d897a532e48480e561f75
ChangeLog | 4 ----
Versions | 2 +-
2 files changed, 1 insertion(+), 5 deletions(-)
commit c9e733b215be209ea028453e10dace2d91a79887
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 14 06:45:41 2006 +0000
Remove commented out macros
ChangeLog | 4 ++++
include/bsd/bsd.h | 14 --------------
2 files changed, 4 insertions(+), 14 deletions(-)
commit 815047342080dc3e8eff1daac0a4694d06e1ae03
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 14 06:43:04 2006 +0000
Move some macros to cdefs.h
ChangeLog | 8 ++++++++
Makefile | 2 +-
include/bsd/bsd.h | 14 +-------------
include/bsd/cdefs.h | 34 ++++++++++++++++++++++++++++++++++
4 files changed, 44 insertions(+), 14 deletions(-)
commit 5372b7368573739ee3bd38c5bb76b187e8241279
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 14 05:39:29 2006 +0000
Move sources to src/
ChangeLog | 24 ++++++++++++++++++++++++
Makefile | 5 +++--
arc4random.c => src/arc4random.c | 0
bsd_getopt.c => src/bsd_getopt.c | 0
err.c => src/err.c | 0
fgetln.c => src/fgetln.c | 0
fmtcheck.c => src/fmtcheck.c | 0
inet_net_pton.c => src/inet_net_pton.c | 0
md5.copyright => src/md5.copyright | 0
md5c.c => src/md5c.c | 0
strlcat.c => src/strlcat.c | 0
strlcpy.c => src/strlcpy.c | 0
12 files changed, 27 insertions(+), 2 deletions(-)
commit 6be6380e10b4f87575060e7839e530642a0182fa
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 14 05:33:38 2006 +0000
Add missing %
Makefile | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
commit 7bd6e03ae0a4d2b039ba6e8fc3b53104dba24512
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 14 05:26:48 2006 +0000
Makefile: Cleanup
(LIB_SRCS): Line wrap.
(LIB_INCLUDES): List only the files, automatically prefix the dir.
(LIB_MANS): Likewise.
ChangeLog | 6 ++++++
Makefile | 10 +++++++---
2 files changed, 13 insertions(+), 3 deletions(-)
commit 39db45e45a8d49a92d1d897a532e48480e561f75
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 14 05:22:15 2006 +0000
Remove optreset
ChangeLog | 4 ++++
Versions | 2 +-
2 files changed, 5 insertions(+), 1 deletion(-)
commit bddcccbcdf4da266893d6f8f5bef807bf39f9bfd
Author: Guillem Jover <guillem@hadrons.org>
Date: Tue Feb 14 05:17:19 2006 +0000
Fix ChangeLog format
ChangeLog | 51 +++++++++++++++++++++++++++------------------------
1 file changed, 27 insertions(+), 24 deletions(-)
commit 7aed0593e00f6369d0b29fbc8cfde653e5187c60
Author: Robert Millan <rmh@aybabtu.com>
Date: Mon Feb 13 20:56:47 2006 +0000
Add bsd_getopt
ChangeLog | 8 ++++++++
Makefile | 4 ++--
Versions | 1 +
bsd_getopt.c | 15 +++++++++++++++
include/bsd/getopt.h | 4 ++++
5 files changed, 30 insertions(+), 2 deletions(-)
commit 7a8c1c864879b3162e1048ddcb3ad59540bb0e0e
Author: Robert Millan <rmh@aybabtu.com>
Date: Mon Feb 13 20:45:13 2006 +0000
Use the same macro (_SYS_QUEUE_H) as <sys/queue.h> for header protection
This prevents collisions.
include/bsd/queue.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
commit 019b5818da4db2c7a053c0b4e065b2fd17979f48
Author: Robert Millan <rmh@aybabtu.com>
Date: Mon Feb 13 20:25:22 2006 +0000
Revert c849ba32af231fba36f4500d0d3290821f4dd7b7
Will use bsd_getopt() wrapper instead.
ChangeLog | 8 --------
Makefile | 2 +-
Versions | 4 ++--
reset_getopt.c | 51 ---------------------------------------------------
4 files changed, 3 insertions(+), 62 deletions(-)
commit 34b269a1cfb9218ba54c05ec2e8148808ebc419d
Author: Robert Millan <rmh@aybabtu.com>
Date: Mon Feb 13 13:02:11 2006 +0000
Fix that FIXME
reset_getopt.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
commit c849ba32af231fba36f4500d0d3290821f4dd7b7
Author: Robert Millan <rmh@aybabtu.com>
Date: Mon Feb 13 09:02:17 2006 +0000
reset_getopt: New function (borrowed from e2fsprogs)
ChangeLog | 8 ++++++++
Makefile | 2 +-
Versions | 4 ++--
reset_getopt.c | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++
4 files changed, 62 insertions(+), 3 deletions(-)
commit 19cc95400b7761073ee3503593a84f299524064a
Author: Robert Millan <rmh@aybabtu.com>
Date: Sat Feb 11 07:06:17 2006 +0000
bsd/queue.h: Replace with patched copy of glibc's <sys/queue.h>
This doesn't affect freebsd6-buildutils.
include/bsd/queue.h | 414 +++++++++++++++++++++++++++++++++++++++++++++++++++-
1 file changed, 408 insertions(+), 6 deletions(-)
commit e8d3b08cc6892c5e5a34458852e556830d05ae07
Author: Robert Millan <rmh@aybabtu.com>
Date: Fri Feb 10 15:22:58 2006 +0000
Add __unused
include/bsd/bsd.h | 1 +
1 file changed, 1 insertion(+)
commit 33eb3ecc41af581080a97300f052df2eea4722e7
Author: Robert Millan <rmh@aybabtu.com>
Date: Fri Feb 10 14:59:03 2006 +0000
Add errc, warnc, verrc and vwarnc
ChangeLog | 10 ++++++++-
Makefile | 4 ++--
Versions | 1 +
err.c | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
include/bsd/err.h | 11 ++++++++++
5 files changed, 86 insertions(+), 3 deletions(-)
commit bc2b90c07b5dbf2850698a4336bdd13384a43087
Author: Aurelien Jarno <aurel32@debian.org>
Date: Tue Dec 20 21:05:34 2005 +0000
Makefile: Fix typo
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
commit dedb8169c4df522f1b9fe5e20e7828dd0861bf84
Author: Aurelien Jarno <aurel32@debian.org>
Date: Tue Dec 20 20:29:47 2005 +0000
Added manpages and fixed fmtcheck
ChangeLog | 5 +-
Makefile | 8 +-
Versions | 1 +
include/bsd/stdlib.h | 9 +++
include/bsd/string.h | 2 +-
man/arc4random.3 | 107 +++++++++++++++++++++++++++
man/fgetln.3 | 128 ++++++++++++++++++++++++++++++++
man/fmtcheck.3 | 117 +++++++++++++++++++++++++++++
man/strlcpy.3 | 204 +++++++++++++++++++++++++++++++++++++++++++++++++++
9 files changed, 575 insertions(+), 6 deletions(-)
commit 91473e2748a0081962a2ecae8ab7787858722efd
Author: Aurelien Jarno <aurel32@debian.org>
Date: Sun Dec 18 04:02:56 2005 +0000
fmtcheck: New function
ChangeLog | 6 ++
Makefile | 2 +-
Versions | 1 +
fmtcheck.c | 267 +++++++++++++++++++++++++++++++++++++++++++++++++++
include/bsd/string.h | 1 +
5 files changed, 276 insertions(+), 1 deletion(-)
commit 657f1b59ceec215ae13f57d03a5ce39c03d30b21
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Oct 31 22:57:10 2005 +0000
Reorganize header files
ChangeLog | 14 ++
Makefile | 2 +-
bsd.h | 266 -------------------------------------
include/bsd/bsd.h | 110 +++++++++++++++
ip_icmp.h => include/bsd/ip_icmp.h | 0
md5.h => include/bsd/md5.h | 0
include/bsd/queue.h | 151 +++++++++++++++++++++
include/bsd/random.h | 9 ++
include/bsd/string.h | 11 ++
md5c.c | 2 +-
10 files changed, 297 insertions(+), 268 deletions(-)
commit 5c2938f589ac8de18646566821dce336fa73a707
Author: Guillem Jover <guillem@hadrons.org>
Date: Fri Oct 28 19:18:39 2005 +0000
Fix ChangeLog
ChangeLog | 11 +++--------
1 file changed, 3 insertions(+), 8 deletions(-)
commit 14b06b3178aeec49947f062d44cf0799c98f831c
Author: Hector Garcia <hector@debian.org>
Date: Fri Aug 5 19:52:06 2005 +0000
Added long description
ChangeLog | 3 +++
1 file changed, 3 insertions(+)
commit a636112284e859557d2acc63c1fb24b2615144ab
Author: Hector Garcia <hector@debian.org>
Date: Wed Aug 3 16:12:59 2005 +0000
General cleanup
Changes on Makefile to fix lack of soft links on shared lib.
Changes on md5.h to reflect md5c.c.
Fixed few packaging problems.
ChangeLog | 9 +++++++++
Makefile | 6 ++++--
md5.h | 8 ++++----
3 files changed, 17 insertions(+), 6 deletions(-)
commit 8928a72173c96d637c080f44b8ecc9763fa3ee94
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jul 25 23:38:43 2005 +0000
Makefile: Add "md5.h" to LIB_INCLUDES
ChangeLog | 4 ++++
Makefile | 2 +-
2 files changed, 5 insertions(+), 1 deletion(-)
commit 3bd2ba1a90fbacd1aa52f683f9666dd66841c6ca
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jul 25 23:37:06 2005 +0000
Versions: Add MD5Init, MD5Update, MD5Pad and MD5Final to LIBBSD_0.0
ChangeLog | 5 +++++
Versions | 4 ++++
2 files changed, 9 insertions(+)
commit 88129874541ecd0039f3cbee20e69a4eb8735252
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jul 25 23:32:52 2005 +0000
Fix ChangeLog format
ChangeLog | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
commit 2154e96175c123584730cf6d2a06e4a20ce737be
Author: Hector Garcia <hector@debian.org>
Date: Mon Jul 25 23:02:40 2005 +0000
Changed files to compile md5c.c
ChangeLog | 5 +++++
Makefile | 4 +---
md5.h | 52 ++++++++++++++++++++++++++++++++++++++++++++++++----
md5c.c | 2 +-
4 files changed, 55 insertions(+), 8 deletions(-)
commit b478b9dd03793e329d81e5b930d62f16fd70c750
Author: Guillem Jover <guillem@hadrons.org>
Date: Mon Jul 25 00:07:29 2005 +0000
fgetln: Cleanup function
Reindent, remove commented code and translate variable names to english
ChangeLog | 5 +++++
fgetln.c | 22 +++++++++-------------
2 files changed, 14 insertions(+), 13 deletions(-)
commit aa605d5f8621f8fe2f96cb4f946c5e11dad885b2
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jul 24 23:55:15 2005 +0000
Add versioned symbols support
ChangeLog | 5 +++++
Makefile | 5 ++++-
Versions | 10 ++++++++++
3 files changed, 19 insertions(+), 1 deletion(-)
commit 07a58e79ab36e023276d45e4a08f94032d652888
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jul 24 23:35:23 2005 +0000
General cleanup
Makefile | 94 +++++++++++++++++++++++++++++++++++++++++-----------------------
md5c.c | 2 +-
2 files changed, 62 insertions(+), 34 deletions(-)
commit 400f4cd55da0bf04f5cc1853b8d45734fb530f7c
Author: Guillem Jover <guillem@hadrons.org>
Date: Sun Jul 24 22:55:16 2005 +0000
Remove autogenerated cruft
build-stamp | 0
configure-stamp | 0
2 files changed, 0 insertions(+), 0 deletions(-)
commit 8654206a04995cf97273e1338a22c05d9a542cad
Author: Hector Garcia <hector@debian.org>
Date: Sun Jul 24 22:51:34 2005 +0000
Importing libbsd
Makefile | 34 ++++++
arc4random.c | 191 ++++++++++++++++++++++++++++++++
bsd.h | 266 ++++++++++++++++++++++++++++++++++++++++++++
build-stamp | 0
configure-stamp | 0
fgetln.c | 32 ++++++
inet_net_pton.c | 214 ++++++++++++++++++++++++++++++++++++
ip_icmp.h | 203 ++++++++++++++++++++++++++++++++++
md5.copyright | 21 ++++
md5.h | 4 +
md5c.c | 336 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
strlcat.c | 74 +++++++++++++
strlcpy.c | 69 ++++++++++++
13 files changed, 1444 insertions(+)
Zerion Mini Shell 1.0