[Midnightbsd-cvs] src [10718] trunk/usr.sbin/lpr/lpd: tag
laffer1 at midnightbsd.org
laffer1 at midnightbsd.org
Sat Jun 9 17:39:57 EDT 2018
Revision: 10718
http://svnweb.midnightbsd.org/src/?rev=10718
Author: laffer1
Date: 2018-06-09 17:39:56 -0400 (Sat, 09 Jun 2018)
Log Message:
-----------
tag
Modified Paths:
--------------
trunk/usr.sbin/lpr/lpd/Makefile
trunk/usr.sbin/lpr/lpd/extern.h
trunk/usr.sbin/lpr/lpd/lpd.8
trunk/usr.sbin/lpr/lpd/lpd.c
trunk/usr.sbin/lpr/lpd/lpdchar.c
trunk/usr.sbin/lpr/lpd/modes.c
trunk/usr.sbin/lpr/lpd/printjob.c
Property Changed:
----------------
trunk/usr.sbin/lpr/lpd/lpd.8
Modified: trunk/usr.sbin/lpr/lpd/Makefile
===================================================================
--- trunk/usr.sbin/lpr/lpd/Makefile 2018-06-09 21:37:35 UTC (rev 10717)
+++ trunk/usr.sbin/lpr/lpd/Makefile 2018-06-09 21:39:56 UTC (rev 10718)
@@ -1,11 +1,12 @@
+# $MidnightBSD$
# From: @(#)Makefile 8.1 (Berkeley) 6/6/93
-# $MidnightBSD$
+# $FreeBSD: stable/10/usr.sbin/lpr/lpd/Makefile 321275 2017-07-20 01:07:02Z ngie $
PROG= lpd
MAN= lpd.8
SRCS= lpd.c printjob.c recvjob.c lpdchar.c modes.c
-CFLAGS+= -I${.CURDIR}/../common_source
+CFLAGS+= -I${.CURDIR:H}/common_source
WARNS?= 1
Modified: trunk/usr.sbin/lpr/lpd/extern.h
===================================================================
--- trunk/usr.sbin/lpr/lpd/extern.h 2018-06-09 21:37:35 UTC (rev 10717)
+++ trunk/usr.sbin/lpr/lpd/extern.h 2018-06-09 21:39:56 UTC (rev 10718)
@@ -1,3 +1,4 @@
+/* $MidnightBSD$ */
/*
* Copyright (c) 1989, 1993
* The Regents of the University of California. All rights reserved.
@@ -27,7 +28,7 @@
* SUCH DAMAGE.
*
* From: @(#)extern.h 8.1 (Berkeley) 6/6/93
- * $MidnightBSD$
+ * $FreeBSD: stable/10/usr.sbin/lpr/lpd/extern.h 216372 2010-12-11 09:38:12Z joel $
*/
#include "lp.cdefs.h" /* A cross-platform version of <sys/cdefs.h> */
Modified: trunk/usr.sbin/lpr/lpd/lpd.8
===================================================================
--- trunk/usr.sbin/lpr/lpd/lpd.8 2018-06-09 21:37:35 UTC (rev 10717)
+++ trunk/usr.sbin/lpr/lpd/lpd.8 2018-06-09 21:39:56 UTC (rev 10718)
@@ -1,3 +1,4 @@
+.\" $MidnightBSD$
.\" Copyright (c) 1983, 1991, 1993
.\" The Regents of the University of California. All rights reserved.
.\"
@@ -26,7 +27,7 @@
.\" SUCH DAMAGE.
.\"
.\" @(#)lpd.8 8.3 (Berkeley) 4/19/94
-.\" $MidnightBSD$
+.\" $FreeBSD: stable/10/usr.sbin/lpr/lpd/lpd.8 239233 2012-08-13 15:16:25Z wblock $
.\"
.Dd June 6, 2001
.Dt LPD 8
Property changes on: trunk/usr.sbin/lpr/lpd/lpd.8
___________________________________________________________________
Added: svn:keywords
## -0,0 +1 ##
+MidnightBSD=%H
\ No newline at end of property
Modified: trunk/usr.sbin/lpr/lpd/lpd.c
===================================================================
--- trunk/usr.sbin/lpr/lpd/lpd.c 2018-06-09 21:37:35 UTC (rev 10717)
+++ trunk/usr.sbin/lpr/lpd/lpd.c 2018-06-09 21:39:56 UTC (rev 10718)
@@ -1,3 +1,4 @@
+/* $MidnightBSD$ */
/*
* Copyright (c) 1983, 1993, 1994
* The Regents of the University of California. All rights reserved.
@@ -41,7 +42,7 @@
#endif
#include "lp.cdefs.h" /* A cross-platform version of <sys/cdefs.h> */
-__MBSDID("$MidnightBSD$");
+__FBSDID("$FreeBSD: stable/10/usr.sbin/lpr/lpd/lpd.c 216372 2010-12-11 09:38:12Z joel $");
/*
* lpd -- line printer daemon.
Modified: trunk/usr.sbin/lpr/lpd/lpdchar.c
===================================================================
--- trunk/usr.sbin/lpr/lpd/lpdchar.c 2018-06-09 21:37:35 UTC (rev 10717)
+++ trunk/usr.sbin/lpr/lpd/lpdchar.c 2018-06-09 21:39:56 UTC (rev 10718)
@@ -1,3 +1,4 @@
+/* $MidnightBSD$ */
/*
* Copyright (c) 1983, 1993
* The Regents of the University of California. All rights reserved.
@@ -34,7 +35,7 @@
#endif
#include "lp.cdefs.h" /* A cross-platform version of <sys/cdefs.h> */
-__MBSDID("$MidnightBSD$");
+__FBSDID("$FreeBSD: stable/10/usr.sbin/lpr/lpd/lpdchar.c 216372 2010-12-11 09:38:12Z joel $");
/*
* Character set for line printer daemon
Modified: trunk/usr.sbin/lpr/lpd/modes.c
===================================================================
--- trunk/usr.sbin/lpr/lpd/modes.c 2018-06-09 21:37:35 UTC (rev 10717)
+++ trunk/usr.sbin/lpr/lpd/modes.c 2018-06-09 21:39:56 UTC (rev 10718)
@@ -1,3 +1,4 @@
+/* $MidnightBSD$ */
/*-
* Copyright (c) 1991, 1993, 1994
* The Regents of the University of California. All rights reserved.
@@ -34,7 +35,7 @@
#endif
#include "lp.cdefs.h" /* A cross-platform version of <sys/cdefs.h> */
-__MBSDID("$MidnightBSD$");
+__FBSDID("$FreeBSD: stable/10/usr.sbin/lpr/lpd/modes.c 216372 2010-12-11 09:38:12Z joel $");
#include <stddef.h>
#include <string.h>
Modified: trunk/usr.sbin/lpr/lpd/printjob.c
===================================================================
--- trunk/usr.sbin/lpr/lpd/printjob.c 2018-06-09 21:37:35 UTC (rev 10717)
+++ trunk/usr.sbin/lpr/lpd/printjob.c 2018-06-09 21:39:56 UTC (rev 10718)
@@ -61,6 +61,7 @@
#include <syslog.h>
#include <fcntl.h>
#include <dirent.h>
+#include <err.h>
#include <errno.h>
#include <inttypes.h>
#include <stdio.h>
@@ -173,9 +174,9 @@
pp->log_file);
(void) open(_PATH_DEVNULL, O_WRONLY);
}
- setgid(getegid());
+ if(setgid(getegid()) != 0) err(1, "setgid() failed");
printpid = getpid(); /* for use with lprm */
- setpgrp(0, printpid);
+ setpgid((pid_t)0, printpid);
/*
* At initial lpd startup, printjob may be called with various
@@ -604,7 +605,7 @@
/*
* Print a file.
* Set up the chain [ PR [ | {IF, OF} ] ] or {IF, RF, TF, NF, DF, CF, VF}.
- * Return -1 if a non-recoverable error occured,
+ * Return -1 if a non-recoverable error occurred,
* 2 if the filter detected some errors (but printed the job anyway),
* 1 if we should try to reprint this job and
* 0 if all is well.
@@ -887,7 +888,7 @@
/*
* Send the daemon control file (cf) and any data files.
- * Return -1 if a non-recoverable error occured, 1 if a recoverable error and
+ * Return -1 if a non-recoverable error occurred, 1 if a recoverable error and
* 0 if all is well.
*/
static int
@@ -1788,7 +1789,7 @@
of_pid = 0;
return;
} else if (*pp->lp) {
- if ((cp = strchr(pp->lp, '@')) != NULL)
+ if (strchr(pp->lp, '@') != NULL)
opennet(pp);
else
opentty(pp);
More information about the Midnightbsd-cvs
mailing list