summaryrefslogtreecommitdiff
path: root/openbsd-compat/bsd-misc.h
Commit message (Collapse)AuthorAgeFilesLines
* Constify utimes in compat library to match specs.Darren Tucker2022-02-251-1/+1
| | | | Patch from vapier at chromium.org.
* Split EGD/PRNGD interface into its own file.Darren Tucker2021-06-181-0/+1
| | | | This will allow us to use it when building --without-openssl.
* Add pselect implementation for platforms without.Darren Tucker2021-06-041-0/+5
| | | | | | | | | | | This is basically the existing notify_pipe kludge from serverloop.c moved behind a pselect interface. It works by installing a signal handler that writes to a pipe that the select is watching, then calls the original handler. The select call in serverloop will become pselect soon, at which point the kludge will be removed from thereand will only exist in the compat layer. Original code by markus, help from djm.
* Improve search for 'struct timespec'.Darren Tucker2020-01-141-0/+2
| | | | | Make struct timespec test consistent with existing timeval test. Include time.h for timespec in compat header where required.
* Add missing bracket in realpath macro.Darren Tucker2019-11-011-1/+1
|
* Use sftp_realpath if no native realpath.Darren Tucker2019-11-011-0/+4
|
* Add implementation of localtime_r.Darren Tucker2019-10-291-0/+4
|
* Fix ifdefs to not mask needed bits.Darren Tucker2019-10-281-2/+1
|
* Move utimensat definition into timespec section.Darren Tucker2019-10-281-10/+12
| | | | | Since utimensat uses struct timespec, move it to the section where we define struct timespec when needed.
* Add minimal fchownat and fchmodat implementations.Darren Tucker2019-01-181-0/+12
| | | | Fixes builds on at least OS X Lion, NetBSD 6 and Solaris 10.
* Add a minimal implementation of utimensat().Darren Tucker2019-01-181-0/+8
| | | | | Some systems (eg older OS X) do not have utimensat, so provide minimal implementation in compat layer. Fixes build on at least El Capitan.
* Check for and work around buggy fflush(NULL).Darren Tucker2018-03-051-0/+4
| | | | | Some really old platforms (eg SunOS4) segfault on fflush(NULL) so check for and work around. With klausz at haus-gisela.de.
* Check if HAVE_DECL_BZERO correctly.Darren Tucker2018-02-271-1/+1
|
* Hook up flock() compat code.Darren Tucker2018-02-261-0/+8
| | | | | Also a couple of minor changes: fail if we can't lock instead of silently succeeding, and apply a couple of minor style fixes.
* Add no-op getsid implmentation.Darren Tucker2018-02-261-0/+4
|
* Check for raise and supply if needed.Darren Tucker2018-02-261-0/+4
|
* Check for bzero and supply if needed.Darren Tucker2018-02-261-0/+4
| | | | | Since explicit_bzero uses it via an indirect it needs to be a function not just a macro.
* Move signal compat code into bsd-signal.{c,h}Darren Tucker2018-02-111-10/+0
|
* Add minimal strsignal for platforms without it.Darren Tucker2017-09-251-0/+4
|
* Add llabs() implementation.V_7_5_P1Darren Tucker2017-03-201-0/+4
|
* Remove obsolete CVS $Id from source files.Darren Tucker2016-08-171-2/+0
| | | | | Since -portable switched to git the CVS $Id tags are no longer being updated and are becoming increasingly misleading. Remove them.
* Strip trailing whitespace.Darren Tucker2016-08-021-1/+1
| | | | | Mechanically strip trailing whitespace on files not synced with OpenBSD (or in the case of bsd-snprint.c, rsync).
* Move err.h replacements into compat lib.Darren Tucker2016-07-131-0/+11
| | | | | Move implementations of err.h replacement functions into their own file in the libopenbsd-compat so we can use them in kexfuzz.c too. ok djm@
* Add a null implementation of pledge.Darren Tucker2015-11-301-0/+4
| | | | Fixes builds on almost everything.
* Use do{}while(0) for no-op functions.Darren Tucker2015-04-071-2/+2
| | | | From FreeBSD.
* - (dtucker) [auth-krb5.c configure.ac openbsd-compat/bsd-misc.h] Add supportDarren Tucker2013-08-041-1/+9
| | | | for building with older Heimdal versions. ok djm.
* - (dtucker) [configure.ac openbsd-compat/bsd-misc.h] bz#2087: Add a nullDarren Tucker2013-05-301-1/+5
| | | | | implementation of endgrent for platforms that don't have it (eg Android). Loosely based on a patch from Nathan Osman, ok djm
* - (djm) [configure.ac openbsd-compat/bsd-misc.c openbsd-compat/bsd-misc.h]Damien Miller2013-03-151-1/+5
| | | | Add a usleep replacement for platforms that lack it; ok dtucker
* - (dtucker) [configure.ac openbsd-compat/bsd-misc.c openbsd-compat/bsd-misc.h]Darren Tucker2013-02-151-1/+5
| | | | Use getpgrp() if we don't have getpgid() (old BSDs, maybe others).
* - (dtucker) [configure.ac openbsd-compat/bsd-misc.h] Add setlinebuf forDarren Tucker2012-07-041-1/+4
| | | | platforms that don't have it. "looks good" tim@
* - (tim) [openbsd-compat/bsd-misc.h sshd.c] Fix conflicting return type forTim Rice2012-02-141-2/+2
| | | | | unsetenv due to rev 1.14 change to setenv.c. Cast unsetenv to void in sshd.c ok dtucker@
* - (tim) [configure.ac openbsd-compat/bsd-misc.h openbsd-compat/bsd-misc.c] AddTim Rice2010-11-081-1/+5
| | | | support for platforms missing isblank(). ok djm@
* - (dtucker) [acconfig.h configure.ac openbsd-compat/bsd-misc.{c,h}]Darren Tucker2005-02-261-5/+1
| | | | | Remove SETGROUPS_NOOP, was only used by Cygwin, which doesn't need it any more. Patch from vinschen at redhat.com.
* - (djm) [acconfig.h configure.ac openbsd-compat/Makefile.inDamien Miller2004-08-151-5/+1
| | | | | | openbsd-compat/bsd-closefrom.c openbsd-compat/bsd-misc.c openbsd-compat/bsd-misc.h openbsd-compat/openbsd-compat.h] Use smarter closefrom() replacement from sudo; ok dtucker@
* - (dtucker) [configure.ac openbsd-compat/misc.c [openbsd-compat/misc.h]Darren Tucker2004-06-251-1/+5
| | | | | | Add closefrom() for platforms that don't have it. (might need some tuning later, but I want to be able to test reexec).
* - (dtucker) [configure.ac sshd.c openbsd-compat/bsd-misc.hDarren Tucker2004-03-081-1/+5
| | | | | openbsd-compat/setenv.c] Unset KRB5CCNAME on AIX to prevent it from being inherited by the child. ok djm@
* - (djm) Simplify the license on code I have written. No code changes.Damien Miller2004-02-171-20/+12
|
* - (bal) openbsd-compat/ clean up. Considate headers, add in $Id$ on ourBen Lindstrom2003-08-291-3/+3
| | | | files, and added missing license to header.
* - (bal) redo how we handle 'mysignal()'. Move it toBen Lindstrom2003-08-251-1/+7
| | | | | openbsd-compat/bsd-misc.c, s/mysignal/signal/ and #define signal to be our 'mysignal' by default. OK djm@
* - (djm) s/get_progname/ssh_get_progname/g to avoid conflict with HeimdalDamien Miller2003-08-221-2/+2
| | | | -lbroken; ok dtucker
* - (dtucker) [configure.ac openbsd-compat/bsd-misc.c openbsd-compat/bsd-misc.h]Darren Tucker2003-08-131-2/+6
| | | | | | | Add a tcsendbreak function for platforms that don't have one, based on the one from OpenBSD. Any more of these and I'll split them out into bsd-termio.[ch].
* - (dtucker) [openbsd-compat/bsd-misc.c openbsd-compat/bsd-misc.h]Darren Tucker2003-08-021-1/+5
| | | | Add a tcgetpgrp function.
* - (djm) Big KNF on openbsd-compat/Damien Miller2003-05-191-14/+13
|
* [configure.ac openbsd-compat/bsd-misc.c openbsd-compat/bsd-misc.h]Tim Rice2003-03-181-1/+10
| | | | add nanosleep(). testing/corrections by Darren Tucker <dtucker@zip.com.au>
* - (bal) typo of setgroup for cygwin. Patch by vinschen@redhat.comBen Lindstrom2002-06-131-2/+2
|
* - (bal) Build noop setgroups() for cygwin to clean up code (For otherBen Lindstrom2002-06-121-1/+6
| | | | | platforms without the setgroups() requirement, you MUST define SETGROUPS_NOOP in the configure.ac) Based on patch by vinschen@redhat.com
* Add truncate() emulation to address Bug 208Tim Rice2002-05-071-1/+4
|
* - (stevesk) use setresgid() for setegid() if neededKevin Steves2001-04-091-1/+5
|
* - (djm) Add CVS Id's to files that we have missedDamien Miller2001-02-091-0/+2
|
* - (bal) Reorder. Move all bsd-*, fake-*, next-*, and cygwin* stuff toBen Lindstrom2001-01-311-0/+70
openbsd-compat/. And resolve all ./configure and Makefile.in issues assocated. Logic: * All OpenBSD functions should have the same filename as in the OpenBSD tree * All 'home brew' functions have bsd-* infront of them. * All 'not really implemented' functions have fake-* infront of them.