Introduction
Introduction Statistics Contact Development Disclaimer Help
Search the path for various sam binaries. - sam - An updated version of the sam…
git clone git://vernunftzentrum.de/sam.git
Log
Files
Refs
LICENSE
---
commit 5f62ec15765ff967a22f32a79cccdb49350fcf3e
parent 5d4838cdd6596c121be8f4f60bb158c7dcbdbf8c
Author: Rob King <[email protected]>
Date: Fri, 27 May 2016 13:30:25 -0500
Search the path for various sam binaries.
Diffstat:
rsam/Makefile | 1 -
rsam/rsam.c | 2 +-
sam/Makefile | 4 ++--
sam/io.c | 4 ++--
4 files changed, 5 insertions(+), 6 deletions(-)
---
diff --git a/rsam/Makefile b/rsam/Makefile
@@ -5,7 +5,6 @@
include ../config.mk
LDFLAGS=
-CFLAGS=-DSAMBIN=\"$(BINDIR)/sam\"
all: rsam
diff --git a/rsam/rsam.c b/rsam/rsam.c
@@ -80,7 +80,7 @@ main(int argc, char **argv)
dup2(CHILD_READ, STDIN_FILENO); close(CHILD_READ);
dup2(CHILD_WRITE, STDOUT_FILENO); close(CHILD_WRITE);
- execl(SAMBIN, "sam", "-R", NULL);
+ execlp("sam", "sam", "-R", NULL);
return EXIT_FAILURE;
}
else if (child < 0)
diff --git a/sam/Makefile b/sam/Makefile
@@ -27,7 +27,7 @@ HOMEDIR=HOME
# where sam is to be installed. SAMSAVEDIR is the name of the directory
# where the samsave file restoration script is stored.
RSAMNAME=sam
-TERMNAME=$(BINDIR)/samterm
+TERMNAME=samterm
SAMDIR=$(BINDIR)
SAMSAVEDIR=$(BINDIR)
@@ -45,7 +45,7 @@ RXNAME=ssh
RXPATHNAME=/usr/bin/ssh
# Set RXSAMNAME to the name of the command to run on the remote host.
-RXSAMNAME=/usr/local/bin/rsam
+RXSAMNAME=rsam
SAMSAVE=/bin/sh\\n$(SAMSAVEDIR)/samsave
diff --git a/sam/io.c b/sam/io.c
@@ -182,7 +182,7 @@ bootterm(char *machine, char **argv, char **end)
close(remotefd1);
argv[0] = "samterm";
*end = 0;
- exec(samterm, argv);
+ execvp(samterm, argv);
fprint(2, "can't exec: ");
perror(samterm);
_exits("damn");
@@ -199,7 +199,7 @@ bootterm(char *machine, char **argv, char **end)
close(pt2h[1]);
argv[0] = "samterm";
*end = 0;
- exec(samterm, argv);
+ execvp(samterm, argv);
fprint(2, "can't exec: ");
perror(samterm);
_exits("damn");
You are viewing proxied material from vernunftzentrum.de. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.