summaryrefslogtreecommitdiffstats
path: root/lib/libc
diff options
context:
space:
mode:
authordelphij <delphij@FreeBSD.org>2015-08-18 22:37:25 +0000
committerdelphij <delphij@FreeBSD.org>2015-08-18 22:37:25 +0000
commit5fe6d5bd0e708a60b671115491a2000548678db7 (patch)
tree832ebb32a269ac8b840393de0856201ca76076ca /lib/libc
parent1d969e58ddc510f9a9294072b742273cacf4fcd0 (diff)
downloadFreeBSD-src-5fe6d5bd0e708a60b671115491a2000548678db7.zip
FreeBSD-src-5fe6d5bd0e708a60b671115491a2000548678db7.tar.gz
- ANSIfy
- Remove the redundant _PATH_RSH definition (paths.h at r96194); - Use pid_t for PIDs - Note that we are at the same level of OpenBSD's counterpart of revision 1.7 (r94757). No functional changes. MFC after: 2 weeks
Diffstat (limited to 'lib/libc')
-rw-r--r--lib/libc/net/rcmdsh.c15
1 files changed, 5 insertions, 10 deletions
diff --git a/lib/libc/net/rcmdsh.c b/lib/libc/net/rcmdsh.c
index bc4e87a..f30ad14 100644
--- a/lib/libc/net/rcmdsh.c
+++ b/lib/libc/net/rcmdsh.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rcmdsh.c,v 1.5 1998/04/25 16:23:58 millert Exp $ */
+/* $OpenBSD: rcmdsh.c,v 1.7 2002/03/12 00:05:44 millert Exp $ */
/*
* Copyright (c) 2001, MagniComp
@@ -49,23 +49,18 @@ __FBSDID("$FreeBSD$");
#include <string.h>
#include <unistd.h>
-#ifndef _PATH_RSH
-#define _PATH_RSH "/usr/bin/rsh"
-#endif
-
/*
* This is a replacement rcmd() function that uses the rsh(1)
* program in place of a direct rcmd(3) function call so as to
* avoid having to be root. Note that rport is ignored.
*/
int
-rcmdsh(ahost, rport, locuser, remuser, cmd, rshprog)
- char **ahost;
- int rport;
- const char *locuser, *remuser, *cmd, *rshprog;
+rcmdsh(char **ahost, int rport, const char *locuser, const char *remuser,
+ const char *cmd, const char *rshprog)
{
struct addrinfo hints, *res;
- int cpid, sp[2], error;
+ int sp[2], error;
+ pid_t cpid;
char *p;
struct passwd *pw;
char num[8];
OpenPOWER on IntegriCloud