Age | Commit message (Collapse) | Author |
|
NetBSD.
|
|
OK tb
|
|
If we are just going to return without parsing TZ, there is no need
to call issetugid(2) first. We only need to call issetugid(2) the
first time TZ is checked or when the value of TZ has changed.
Previously, we called issetugid(2) for every call to the functions
described by localtime(3). OK deraadt@
|
|
related conclusion that our syslog_r should not stomp on errno.
The errno being returned from sendsyslog() isn't exactly compatible
with the what a legacy syslog_r() would do here anyways, and it is
better to just be void and non-stomping;
ok millert bluhm
|
|
Requested by robert@
OK mvs@ millert@ deraadt@
|
|
found with noderef.cocci, ok deraadt@
|
|
ok deraadt
|
|
page size, rather than relying upon mprotect to round up to the actual mmu
page size.
This repairs malloc operation on systems where the malloc page size
(1 << _MAX_PAGE_SHIFT) is larger than the mmu page size.
ok otto@
|
|
need any of its contents.
ok claudio@ kettenis@
|
|
Also, the details described in sigaltstack(2) are no longer true.
ok jmc
|
|
that it has been replaced with pinsyscalls(2) [which tells the kernel
the location of all system calls in libc.so]
floated to various people before release, but it was prudent to wait.
|
|
abuse END macros to place the number at the end of the syscall wrapper
rather than in the middle of it, so that there is no need to branch
around it; this saves two instructions per syscall number >= 128.
While there, also tweak the error return (SET_ERRNO_AND_RETURN) to only
return a 64-bit value for lseek; this saves another instruction for
all other syscalls.
With input from guenther@; "Anything that makes the machine faster" deraadt@
|
|
checks from all the filesystems that support hardlinks at all into
the VFS layer. Simplify, EPERM description in link(2).
ok miod@ mpi@
|
|
Document that in the manpage and stop using it internally.
ok deraadt@ millert@ jmc@
|
|
|
|
ok deraadt@ jmc@
|
|
|
|
No shlib_version change needed, jumping on the version bump of the mkdtems
addition.
|
|
OK deraadt@ tb@
|
|
in ports
Even if those _[BCNLPSUX] defines are in the reserved namespace, some
ports make use of those identifiers and thus need pointless
headscratching and patches. Just use a longer reserved prefix.
We can't just #undef those defines as they are used in libc.
Change similar to what NetBSD did around 2010. Went through base builds
and an amd64 bulk build, the only fallout was lib(e)stdc++ base_ctype.h.
"make includes" will install the latest ctype.h and libstdc++ ctype_base.h.
"makes sense" deraadt@, ok sthen@ tb@
|
|
Similar to what NetBSD did around 2010, this lets us move some defines
in ctype.h to the _CTYPE_ prefix. No functional change.
"makes sense" deraadt, ok sthen@ tb@
|
|
getpwent.c (isn't it horrible), and therefore lack visibility of
the the libc-internal __hash_open() function. Use -DFORCE_DBOPEN
in chpass/Makefile and passwd/Makefile and adjust getpwent.c to
use the external visible interface. Is there a better way?
|
|
consistant regarding bcrypt,a instead of blowfish,a. "blowfish"
is a historical alias which we don't need to document as firmly
as "bcrypt".
report about difficult manual page discovery from ataraxia937
ok millert
|
|
libc-private __hash_open() than the generic dbopen(3) which pulls
in all 3 database backends.
ok millert
|
|
static binaries. If we call libc-private __hash_open() instead, it
results in a ~40K reduction in many static binaries.
ok millert
|
|
pre-initialized ypconnect(2) socket. That calls clntudp_bufcreate(),
which contains code checking if the socket and address are configured..
If not, socket(2) is called, or an address allocation is performed via
the portmapper (which calls a whole lot more code).
Split clnt_udp.c into two .c files (which will compile as seperate .o
files), and create a new libc-private clntudp_bufcreate_simple() function
which skips the socket and address work.
Result: In most static binaries, this reduces the text segment by
~100K, and removes 5-7 system call stubs -- which might matter for
non-pledged binaries with otherwise lack socket(2).
ok millert jmatthew
|
|
memory; ok kettenis
|
|
headers start at a higher address). Using the wrong base address meant
that we were protecting the wrong address range for the malloc internals
which made the code error out now that mimmutable(2) no longer allows an
RW->R transition. Issue found by gkoehler@ who got most of the way
towards a proper fix.
ok deraadt@
|
|
prodding from kettenis
|
|
chrome v8_flags variable's placement in bss, and as a workaround made
it possible to demote a mimmutable mapping's permissions from RW to R.
Further mimmutable-related work in libc's malloc created the same
problem, which led to a better design: objects could be placed into
.openbsd.mutable region, and then at runtime their permission and
immutability could be manipulated better. So the RW to R demotion
logic is no longer being used, and now this semantic is being deleted.
ok kettenis
|
|
Previously, calling any of the mktemp(3) family would pull in
lstat(2), open(2) and mkdir(2). Now, only the necessary system
calls will be reachable from the binary. OK deraadt@ guenther@
|
|
|
|
OK deraadt@
|
|
an execve(2) stub. The new pinsyscalls(2) that applies to all system
calls has made this redundant.
|
|
ok miod tb
|
|
When we made sure that getaddrinfo(3) always resolves "localhost" to
the loopback address we forgot to set ai_canonname if AI_CANONNAME or
AI_FQDN is set. On a successful call ai_canonname has to be a NUL-terminated
string if either of those flags are set.
Problem observed by a@alexis-fouilhe.fr in smtpd(8) with a hostname of
"localhost".
OK millert
|
|
Negative absolute timeouts are valid inputs.
With input from kettenis@.
Thread: https://marc.info/?l=openbsd-tech&m=170467558006767&w=2
ok guenther@
|
|
Compare the current time with the absolute timeout before computing
the relative timeout to avoid arithmetic overflow. Fixes a bug where
large negative absolute timeouts are subtracted into large positive
relative timeouts and incorrectly cause the caller to block.
While here, use timespeccmp(3) and timespecsub(3) to simplify the
code.
Thread: https://marc.info/?l=openbsd-tech&m=169945962503129&w=2
|
|
ld.so already did, will both be EPERM
|
|
- zap an unused Pp
|
|
bit of optimization; ok tb@ asou@
|
|
for how it is used (in ld.so, it's not like anyone else can call it).
Also document the errors..
|
|
put their macros, and also turn a few "EXIT" into "END" for consistency with
other platforms. NFCI
ok kettenis@ deraadt@
|
|
|
|
|
|
it is a dangerous alternative entry point for all system calls, and thus
incompatible with the precision system call entry point scheme we are
heading towards. This has been a 3-year mission:
First perl needed a code-generated wrapper to fake syscall(2) as a giant
switch table, then all the ports were cleaned with relatively minor fixes,
except for "go". "go" required two fixes -- 1) a framework issue with
old library versions, and 2) like perl, a fake syscall(2) wrapper to
handle ioctl(2) and sysctl(2) because "syscall(SYS_ioctl" occurs all over
the place in the "go" ecosystem because the "go developers" are plan9-loving
unix-hating folk who tried to build an ecosystem without allowing "ioctl".
ok kettenis, jsing, afresh1, sthen
|
|
Required for strict-alignment architectures and a good idea on others.
ok deraadt@
|
|
arguments, so we have to cope.
|
|
|
|
ok kettenis, some tweaks from jmc
|