summaryrefslogtreecommitdiffstats
path: root/usr.sbin/lpd (follow)
Commit message (Collapse)AuthorAgeFilesLines
* fix cast in isdigit() calls.benno2020-03-162-6/+6
| | | | ok eric@ deraadt@
* fix bogus pointer/double free crash, when /etc/printcap db file is not present,mestre2019-11-081-4/+4
| | | | | | | by adding a missing check for the return value -1 on both cgetfirst(3) and cgetnext(3) OK millert@ deraadt@
* snprintf/vsnprintf return < 0 on error, rather than -1.deraadt2019-07-031-2/+2
|
* When system calls indicate an error they return -1, not some arbitraryderaadt2019-06-282-4/+4
| | | | | | value < 0. errno is only updated in this case. Change all (most?) callers of syscalls to follow this better, and let's see if this strictness helps us in the future.
* do not call freeaddrinfo() on a NULL pointer.eric2019-04-061-2/+3
|
* accept the NULL string in the proc message formatting api and simplifyeric2019-04-044-30/+37
| | | | code accordingly.
* (unsigned) means (unsigned int) which on ptrdiff_t or size_t or otherderaadt2019-02-131-3/+3
| | | | | | larger types really is a range reduction... Almost any cast to (unsigned) is a bug. ok millert tb benno
* - odd condition/test in PF lexersashan2018-11-011-2/+3
| | | | | | | | | | | | | | (and other lexers too) This commit rectifies earlier change: in the lex... even inside quotes, a \ followed by space or tab should expand to space or tab, and a \ followed by newline should be ignored (as a line continuation). compatible with the needs of hoststated (which has the most strict quoted string requirements), and ifstated (where one commonly does line continuations in strings). OK deraadt@, OK millert@
* replace malloc()+strlcpy() with strndup() in cmdline_symset().miko2018-09-071-9/+4
| | | | "looks good" gilles@ halex@
* synchronize resolver code with smtpderic2018-09-055-53/+63
|
* Do for most running out of memory err() what was done for most runningkrw2018-07-111-4/+4
| | | | | | | | out of memory log_warn(). i.e. ("%s", __func__) instead of manual function names and redundant verbiage about which wrapper detected the out of memory condition. ok henning@
* No need to mention which memory allocation entry point failed (malloc,krw2018-07-091-4/+4
| | | | | | | | | calloc or strdup), we just need to log that we ran out of memory in a particular function. Recommended by florian@ and deraadt@ ok benno@ henning@ tb@
* Import lpd, a re-implementation of the lpr daemon following the latesteric2018-04-2726-0/+11713
OpenBSD coding practices (fork+exec/privsep/pledge/...). It is only intended to replace the lpd(8) daemon for the moment, not the lpr(1), lprm(1), lpq(1) and lpc(8) commands. This is a work in progress. The server part should be fairly functionnal, but the printer part is not complete: remote printers should work, for local printers it depends on the setup. Anyway, at this point it's better in the tree than rotting on my disk. ok deraadt@