|
847e682f
|
2021-02-07T00:09:30
|
|
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.
|
|
37a9b56c
|
2021-02-06T23:43:12
|
|
Import pwcache module from OpenBSD
|
|
01f0d1ea
|
2020-12-31T12:46:03
|
|
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>
|
|
3548c5f6
|
2019-08-26T05:39:17
|
|
Add missing strnvisx() to the symbols script
Fixes: commit 2d7de186e9cb19a756c0630ee85cb3f2d29b3484.
|
|
5745ca03
|
2019-08-06T15:49:41
|
|
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.
|
|
e4e15ed2
|
2018-05-22T13:50:44
|
|
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
|
|
e13b1a33
|
2018-05-21T00:20:49
|
|
Import strtoi() and strtou() functions from NetBSD
|
|
2d7de186
|
2018-05-21T03:09:05
|
|
Update vis/unvis modules from NetBSD
|
|
facbddb6
|
2018-05-20T19:18:18
|
|
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.
|
|
993828d8
|
2018-05-21T01:11:46
|
|
Add flopenat() function from FreeBSD
|
|
d6c35f61
|
2017-01-10T04:33:15
|
|
Do not provide funopen() on musl
Fixes: https://bugs.debian.org/818246
|
|
45443583
|
2015-09-23T19:37:37
|
|
Add explicit_bzero() function from OpenBSD
|
|
faa005cb
|
2014-06-27T02:05:11
|
|
Add reallocarray() function from OpenBSD
Signed-off-by: Guillem Jover <guillem@hadrons.org>
|
|
36aca8c0
|
2014-06-26T21:43:55
|
|
Add stringlist module from NetBSD
|
|
e8f93003
|
2014-06-26T21:32:11
|
|
Add getbsize() function
Import code from DragonFlyBSD and man page from FreeBSD.
|
|
8d16c3df
|
2013-10-11T05:43:42
|
|
Add timeconv module from FreeBSD
Inline license information from FreeBSD root dir COPYRIGHT file.
|
|
f41fdcf1
|
2013-10-21T05:07:56
|
|
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.
|
|
c5b95902
|
2013-07-11T12:25:54
|
|
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
|
|
e9933255
|
2013-05-25T17:11:53
|
|
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.
|
|
a97ce513
|
2012-11-23T21:19:45
|
|
Add new fgetwln() function
Man page taken from FreeBSD.
|
|
ee0489eb
|
2012-08-07T08:44:30
|
|
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>
|
|
1be0bdb2
|
2012-11-25T21:13:38
|
|
Add new strnstr() function
Taken from FreeBSD.
|
|
ff0d700d
|
2012-11-23T17:16:43
|
|
Add new wcslcat() and wcslcpy() functions
Taken from FreeBSD.
|
|
64348583
|
2011-12-31T04:30:48
|
|
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>
|
|
943939d0
|
2011-12-31T08:39:44
|
|
Add new closefrom() function
Code taken from sudo, man page from FreeBSD.
|
|
0aa777f4
|
2011-12-31T07:35:52
|
|
Move .pc and .map files to src/
|