summaryrefslogtreecommitdiffstats
path: root/usr.sbin/lpr/runqueue
Commit message (Collapse)AuthorAgeFilesLines
* Mega lpd/lpd upgrade, part I:wollman1997-12-024-349/+337
| | | | | | | | | | | | | | | - Get rid of a lot of the static variables which were shared by many routines and programs in the suite. - Create an abstract interface to the printcap database, so that other retrieval and iteration mechanisms could be developed (e.g., YP, Hesiod, or automatic retrieval from a trusted server). - Give each capability a human-readable name in addition to the historic two-character one. - Otherwise generally clean up a lot of dark corners. Many still remain. - When submitting jobs, use the official login name record (from getlogin()) if there is one, rather than reverse-mapping the uid. More to come...
* Argl! Who's got the pointy hat these days? Hand it over to me, ASAP!joerg1997-11-071-0/+2
| | | | | When setting an alarm that didn't trigger, i gotta clear it again before going on. Hmpf!
* Improve my hack from rev 1.6 of displayq.c, and make the TCPjoerg1997-10-141-0/+17
| | | | | | | | connection timeout controllable by a new printcap(5) capability named `ct' (connectiom timeout), defaulting to 120 seconds (which is the default TCP connection timeout). Would anybody see a problem with merging all this into RELENG_2_2?
* Two minor, pedantic fixes from bde for my last pedantic fixes, plusimp1997-07-291-7/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | the following from recent OpenBSD changes. These changes (and all I've made) should be merged back into 2.2 when they are vetted in -current. common.c: OpenBSD 1.7: mickey: #if __STDC__ --> #ifdef __STDC__ displayq.c: OpenBSD 1.8: deraadt: 1 byte oflows; millert rmjob.c: OpenBSD 1.8: deraadt: 1 byte oflows; millert cmds.c: OpenBSD 1.9: grr: restore traditional "all" keyword option - see lpc(8) [[ This makes lpc status all work again -- imp ]] printjob.c: OpenBSD 1.17: deraadt: use sendmail -t OpenBSD 1.16: mickey: #if __STDC__ --> #ifdef __STDC__ OpenBSD 1.15: deraadt: 1 byte oflow; Don.Lewis@tsc.tdk.com recvjob.c: OpenBSD 1.11: mickey: #if __STDC__ --> #ifdef __STDC__ lpr.c: OpenBSD 1.19: mickey: #if __STDC__ --> #ifdef __STDC__ Obtained from: OpenBSD
* Fix boatloads of buffer overflows from the OpenBSD tree.imp1997-07-291-28/+42
| | | | | Be pedantic about always using sizeof(blah) vs sizeof (blah) or sizeof blah. Obtained from:OpenBSD
* index -> strchr and rindex -> strrchr to reduce the number of gratuitousimp1997-07-231-5/+5
| | | | | | diffes with NetBSD/OpenBSD. These changes seem to predate the NetBSD/OpenBSD split, so it is hard to give proper credit for them. Obtained from: OpenBSD.
* Support input and output filters with remote printing.brian1997-04-121-16/+173
| | | | | Output filters are executed on a per-file basis as it's necessary to supply the file size to the "other side".
* Revert $FreeBSD$ to $Id$peter1997-02-221-1/+1
|
* Make the long-awaited change from $Id$ to $FreeBSD$jkh1997-01-141-1/+1
| | | | | | | | This will make a number of things easier in the future, as well as (finally!) avoiding the Id-smashing problem which has plagued developers for so long. Boy, I'm glad we're not using sup anymore. This update would have been insane otherwise.
* lpc/cmds.c:imp1996-10-271-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | From NetBSD via OpenBSD to fix NetBSD PR #506 More descriptive message for printer status (OpenBSD: 1.2) Various warnings cleaned up (OpenBSD: 1.4) lpc/lpc.c: Various warnings cleaned up (OpenBSD: 1.3) lpd/lpd.c: Remove trailing blank lines (OpenBSD: 1.2) Potential umask problem with creating /dev/printer (OpenBSD: 1.4 and 1.5) Ftp bounce attack (untested on FreeBSD) (OpenBSD: 1.6, 1.8, 1.9) Fencepost in strncpy (OpenBSD: 1.6) lpd/printjob.c: Fix from freebsd for waiting for an exiting filter, that appears not in the FreeBSD CVS tree. (OpenBSD: 1.6) lpd/recvjob.c: Buffer overflow protection: use strncpy rather than strcpy. (OpenBSD: 1.3) lpr/lpr.c: NetBSD change of return type for main() (OpenBSD: 1.2) Restrict time running as root (OpenBSD: 1.7) Use getcwd rather than getwd (from NetBSD) Use snprintf rather than sprintf (OpenBSD: 1.8) Minor tweak to end of loop and buffer overflow sanity. card() overflow already in FreeBSD (OpenBSD: 1.9) lptest/lptest.c: void -> int return type of main, from NetBSD via OpenBSD (OpenBSD: 1.2) pac/pac.c: void -> int return type of main, from NetBSD via OpenBSD (OpenBSD: 1.3) Obtained from: OpenBSD
* Close files up to getdtablesize(), instead of up to NOFILE.bde1996-09-291-5/+9
| | | | lpd was one of 3 programs in /usr/src that (mis)used NOFILE.
* Cleanup.joerg1996-05-093-2/+5
| | | | | | | | | The removed files are no longer needed, they are actually labelled as ``Use only if you are not 4.4BSD''. (Yeah, the ol' crufty printcap.c is really gone!) Properly declare all external objects in files ending in .h, as opposed to embed them into files ending in .c.
* Pull a bunch of fixes from the 4.4BSD-Lite2 branch. It's reallyjoerg1996-05-051-75/+173
| | | | | | | | | | | | surprising how many trivial errors there have been... :-) Some more cleanup is needed, but i'd like to separate the Lite2 changes from other work, that's why this goes into a different commit. People with serial printers should see whether i have broken the stty- style printcap options (i hope not). Inspired by: Sergey Shkonda <serg@bcs1.bcs.zaporizhzhe.ua>
* Makefile: Add new modes.c file to list of objects.sef1996-04-032-28/+248
| | | | | | | | | | printjob.c: Use termios instead of sgtty structs and ioctls; remove support for fs/fc/xs/xc capabilities, and replace them with the ms capability (stty-like words, instead of octal bit patterns). modes.c: Modified from stty's file, parses comma-seperated list of tty modes (e.g., "cs8,-paren,-opost"). Reviewed by: rgrimes, joerg
* Initialize the group list so that any filter programs that arempp1995-09-021-1/+9
| | | | run by lpd are not run with root's groups.
* The other day someone brought me an old Apple Laserwriter II with a serialwpaul1995-07-311-0/+2
| | | | | | | interface set at 57600 baud, and I found out the hard way that lpd doesn't know about speeds greater than 38400, even though <sys/ttydev.h> also permits 57600 and 115200 baud. Fix this by adding B57600 and B115200 to the 'bauds' table. (The Apple printer worked properly once I did this, BTW. :)
* Remove trailing whitespace.rgrimes1995-05-302-11/+11
|
* Close PR:jkh1995-04-271-0/+9
| | | | | | | | | | | | | | >Number: 368 >Category: bin >Synopsis: Lpd doesn't log errors after failed exec >Description: If an exec done by lpd fails, nothing is sent to the system log indicating what went wrong. This is because lpd closes all of the file descriptors before doing the exec, thus closing the syslog file descriptor in the process. [Fix applied] Submitted by: pritc003@maroon.tc.umn.edu
* Use the "-F" option to /bin/pr now that we have it (thanks to Posix).joerg1995-01-081-2/+3
| | | | | | This helps for printers that tend to get out of sync. (For the cautious folks: we used to have it in 1.1.5, too. But GNU pr used "-f" for it.)
* BSD 4.4 Lite usr.sbin Sourcesrgrimes1994-05-263-0/+2482
OpenPOWER on IntegriCloud