summaryrefslogtreecommitdiff
path: root/src/lib/ipcp.c
diff options
context:
space:
mode:
authordimitri staessens <dimitri.staessens@intec.ugent.be>2016-06-20 21:58:17 +0200
committerdimitri staessens <dimitri.staessens@intec.ugent.be>2016-06-20 21:58:17 +0200
commit34f96731f5fb8ab8a1f7018366fc28fd041d73e2 (patch)
treeaff0b0ed3474c7cdb5f6ba7e62ca5e33ccedb814 /src/lib/ipcp.c
parent6270143e57306d11be5c02ee3c7857808583c0f5 (diff)
parent550cfa775b048abe183c4fdcc8ada8476e562185 (diff)
downloadouroboros-34f96731f5fb8ab8a1f7018366fc28fd041d73e2.tar.gz
ouroboros-34f96731f5fb8ab8a1f7018366fc28fd041d73e2.zip
Merged in sandervrijders/ouroboros/be (pull request #134)
build: Change install directories and set correct permissions
Diffstat (limited to 'src/lib/ipcp.c')
-rw-r--r--src/lib/ipcp.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/lib/ipcp.c b/src/lib/ipcp.c
index 89756235..a43afd21 100644
--- a/src/lib/ipcp.c
+++ b/src/lib/ipcp.c
@@ -105,11 +105,11 @@ pid_t ipcp_create(char * ipcp_name,
pid_t pid = 0;
char irmd_pid[10];
size_t len = 0;
- char * ipcp_dir = "bin";
+ char * ipcp_dir = "sbin/";
char * full_name = NULL;
char * exec_name = NULL;
- sprintf (irmd_pid, "%u", getpid());
+ sprintf(irmd_pid, "%u", getpid());
pid = fork();
if (pid == -1) {
@@ -135,7 +135,7 @@ pid_t ipcp_create(char * ipcp_name,
len += strlen(INSTALL_DIR);
len += strlen(ipcp_dir);
len += strlen(exec_name);
- len += 3;
+ len += 1;
full_name = malloc(len + 1);
if (full_name == NULL) {
@@ -144,9 +144,7 @@ pid_t ipcp_create(char * ipcp_name,
}
strcpy(full_name, INSTALL_DIR);
- strcat(full_name, "/");
strcat(full_name, ipcp_dir);
- strcat(full_name, "/");
strcat(full_name, exec_name);
full_name[len] = '\0';