summaryrefslogtreecommitdiffstats
path: root/usr.sbin/rpc.ypupdated
diff options
context:
space:
mode:
authorcharnier <charnier@FreeBSD.org>1997-10-13 11:22:39 +0000
committercharnier <charnier@FreeBSD.org>1997-10-13 11:22:39 +0000
commit8459f389a168bc4c5109f83e755a73813f58b8bb (patch)
tree34d312378554ef5de4d8763fd35100eb424ff996 /usr.sbin/rpc.ypupdated
parent67de6ed0a2d20541b0f95abf9e5e36e1b8d32de4 (diff)
downloadFreeBSD-src-8459f389a168bc4c5109f83e755a73813f58b8bb.zip
FreeBSD-src-8459f389a168bc4c5109f83e755a73813f58b8bb.tar.gz
Use err(3). Remove multiply defined Id string.
Diffstat (limited to 'usr.sbin/rpc.ypupdated')
-rw-r--r--usr.sbin/rpc.ypupdated/update.c13
-rw-r--r--usr.sbin/rpc.ypupdated/yp_dbdelete.c13
-rw-r--r--usr.sbin/rpc.ypupdated/yp_dbupdate.c11
-rw-r--r--usr.sbin/rpc.ypupdated/ypupdated_main.c17
-rw-r--r--usr.sbin/rpc.ypupdated/ypupdated_server.c11
5 files changed, 30 insertions, 35 deletions
diff --git a/usr.sbin/rpc.ypupdated/update.c b/usr.sbin/rpc.ypupdated/update.c
index d6e142f..5b11d83 100644
--- a/usr.sbin/rpc.ypupdated/update.c
+++ b/usr.sbin/rpc.ypupdated/update.c
@@ -27,9 +27,14 @@
* 2550 Garcia Avenue
* Mountain View, California 94043
*/
+
#ifndef lint
+#if 0
static char sccsid[] = "@(#)update.c 1.2 91/03/11 Copyr 1986 Sun Micro";
#endif
+static const char rcsid[] =
+ "$Id$";
+#endif /* not lint */
/*
* Copyright (C) 1986, 1989, Sun Microsystems, Inc.
@@ -64,15 +69,7 @@ static char sccsid[] = "@(#)update.c 1.2 91/03/11 Copyr 1986 Sun Micro";
#define YPOP_STORE 4 /* add, or change */
#endif
-#ifdef notdef
-extern char *getpass();
-extern char *malloc();
-#endif
-
#ifdef YP
-#ifdef notdef
-static char *basename();
-#endif
static char SHELL[] = "/bin/sh";
static char YPDBPATH[]="/var/yp"; /* This is defined but not used! */
static char PKMAP[] = "publickey.byname";
diff --git a/usr.sbin/rpc.ypupdated/yp_dbdelete.c b/usr.sbin/rpc.ypupdated/yp_dbdelete.c
index 622b445..304db74 100644
--- a/usr.sbin/rpc.ypupdated/yp_dbdelete.c
+++ b/usr.sbin/rpc.ypupdated/yp_dbdelete.c
@@ -28,10 +28,13 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
- *
- * $Id: yp_dbdelete.c,v 1.1 1996/12/26 05:43:03 wpaul Exp wpaul $
- *
*/
+
+#ifndef lint
+static const char rcsid[] =
+ "$Id$";
+#endif /* not lint */
+
#include <stdio.h>
#include <stdlib.h>
#include <fcntl.h>
@@ -45,10 +48,6 @@
#include <rpcsvc/yp.h>
#include "ypxfr_extern.h"
-#ifndef lint
-static const char rcsid[] = "$Id: yp_dbdelete.c,v 1.1 1996/12/26 05:43:03 wpaul Exp wpaul $";
-#endif
-
int yp_del_record(dbp,key)
DB *dbp;
DBT *key;
diff --git a/usr.sbin/rpc.ypupdated/yp_dbupdate.c b/usr.sbin/rpc.ypupdated/yp_dbupdate.c
index 5a395bb..db84c77 100644
--- a/usr.sbin/rpc.ypupdated/yp_dbupdate.c
+++ b/usr.sbin/rpc.ypupdated/yp_dbupdate.c
@@ -28,10 +28,13 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
- *
- * $Id: yp_dbupdate.c,v 1.1 1996/12/26 06:00:13 wpaul Exp $
*/
+#ifndef lint
+static const char rcsid[] =
+ "$Id$";
+#endif /* not lint */
+
#include <sys/fcntl.h>
#include <stdio.h>
@@ -46,10 +49,6 @@ struct dom_binding {};
#include "ypxfr_extern.h"
#include "ypupdated_extern.h"
-#ifndef lint
-static const char rcsid[] = "$Id: yp_dbupdate.c,v 1.1 1996/12/26 06:00:13 wpaul Exp $";
-#endif
-
static int yp_domake(map, domain)
char *map;
char *domain;
diff --git a/usr.sbin/rpc.ypupdated/ypupdated_main.c b/usr.sbin/rpc.ypupdated/ypupdated_main.c
index 95bc51d..854f611 100644
--- a/usr.sbin/rpc.ypupdated/ypupdated_main.c
+++ b/usr.sbin/rpc.ypupdated/ypupdated_main.c
@@ -28,10 +28,13 @@
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
- *
- * $Id: ypupdated_main.c,v 1.1 1996/12/25 19:31:28 wpaul Exp wpaul $
*/
+#ifndef lint
+static const char rcsid[] =
+ "$Id$";
+#endif /* not lint */
+
#include "ypupdate_prot.h"
#include <stdio.h>
#include <stdlib.h> /* getenv, exit */
@@ -63,9 +66,6 @@
#endif
#define _RPCSVC_CLOSEDOWN 120
-#ifndef lint
-static const char rcsid[] = "$Id: ypupdated_main.c,v 1.1 1996/12/25 19:31:28 wpaul Exp wpaul $";
-#endif /* not lint */
int _rpcpmstart; /* Started by a port monitor ? */
static int _rpcfdtype;
/* Whether Stream or Datagram ? */
@@ -87,7 +87,7 @@ void _msgout(char* msg)
if (_rpcpmstart)
syslog(LOG_ERR, msg);
else
- (void) fprintf(stderr, "%s\n", msg);
+ warnx("%s", msg);
#else
syslog(LOG_ERR, msg);
#endif
@@ -146,7 +146,7 @@ ypupdated_svc_run()
if (errno == EINTR) {
continue;
}
- perror("svc_run: - select failed");
+ warn("svc_run: - select failed");
return;
case 0:
continue;
@@ -181,10 +181,11 @@ static void reaper(sig)
void usage()
{
- fprintf(stderr, "%s [-p path]\n", progname);
+ fprintf(stderr, "rpc.ypupdatedd [-p path]\n");
exit(0);
}
+int
main(argc, argv)
int argc;
char *argv[];
diff --git a/usr.sbin/rpc.ypupdated/ypupdated_server.c b/usr.sbin/rpc.ypupdated/ypupdated_server.c
index 11b007e..4741c56 100644
--- a/usr.sbin/rpc.ypupdated/ypupdated_server.c
+++ b/usr.sbin/rpc.ypupdated/ypupdated_server.c
@@ -34,10 +34,13 @@
* Written by Bill Paul <wpaul@ctr.columbia.edu>
* Center for Telecommunications Research
* Columbia University, New York City
- *
- * $Id: ypupdated_server.c,v 1.3 1996/12/26 06:06:05 wpaul Exp wpaul $
*/
+#ifndef lint
+static const char rcsid[] =
+ "$Id$";
+#endif /* not lint */
+
#include <stdio.h>
#include <rpc/rpc.h>
#include <rpc/auth_des.h>
@@ -50,10 +53,6 @@
#include "yp_extern.h"
#include "ypxfr_extern.h"
-#ifndef lint
-static const char rcsid[] = "$Id: ypupdated_server.c,v 1.3 1996/12/26 06:06:05 wpaul Exp wpaul $";
-#endif
-
int children = 0;
int forked = 0;
OpenPOWER on IntegriCloud