summaryrefslogtreecommitdiff
path: root/src/install.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/install.c')
-rw-r--r--src/install.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/install.c b/src/install.c
index e6f95a9..7ca734d 100644
--- a/src/install.c
+++ b/src/install.c
@@ -7,13 +7,15 @@
#include "logmsg.h"
#include "open.h"
+#include "hier.h"
+
extern void hier();
#define WHO "install"
int fdsourcedir = -1;
-void h(char *home, int uid, int gid, int mode)
+void h(const char *home, int uid, int gid, int mode)
{
if (mkdir(home, 0700) == -1)
if (errno != EEXIST) logmsg(WHO, 111, FATAL, B("unable to mkdir: ", home));
@@ -21,7 +23,7 @@ void h(char *home, int uid, int gid, int mode)
if (chmod(home, mode) == -1) logmsg(WHO, 111, FATAL, B("unable to chmod: ", home));
}
-void d(char *home, char *subdir, int uid, int gid, int mode)
+void d(const char *home, char *subdir, int uid, int gid, int mode)
{
if (chdir(home) == -1) logmsg(WHO, 110, FATAL, B("unable to switch to: ", home));
if (mkdir(subdir, 0700) == -1)
@@ -30,7 +32,7 @@ void d(char *home, char *subdir, int uid, int gid, int mode)
if (chmod(subdir, mode) == -1) logmsg(WHO, 111, FATAL, B("unable to chmod: ", home, "/", subdir));
}
-void p(char *home, char *fifo, int uid, int gid, int mode)
+void p(const char *home, char *fifo, int uid, int gid, int mode)
{
if (chdir(home) == -1) logmsg(WHO, 110, FATAL, B("unable to switch to: ", home));
if (fifo_make(fifo, 0700) == -1)
@@ -44,7 +46,7 @@ buffer bi;
char outbuf[BUFFER_OUTSIZE];
buffer bo;
-void c(char *home, char *subdir, char *file, int uid, int gid, int mode)
+void c(const char *home, char *subdir, char *file, int uid, int gid, int mode)
{
int fdin;
int fdout;
@@ -77,7 +79,7 @@ void c(char *home, char *subdir, char *file, int uid, int gid, int mode)
if (chmod(file, mode) == -1) logmsg(WHO, 111, FATAL, B("unable to chmod .../", subdir, "/", file));
}
-void z(char *home, char *file, int len, int uid, int gid, int mode)
+void z(const char *home, char *file, int len, int uid, int gid, int mode)
{
int fdout;