aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin/pkg_install/create
diff options
context:
space:
mode:
authorMaxim Sobolev <sobomax@FreeBSD.org>2001-05-17 12:33:39 +0000
committerMaxim Sobolev <sobomax@FreeBSD.org>2001-05-17 12:33:39 +0000
commita31ab3efc4a2d63d6ed87bd8519a78da81e58e14 (patch)
tree76b3f6adfd28deedcc32856f4fa822d7c5510f79 /usr.sbin/pkg_install/create
parent482778a57a3c5ac47696ba8b619bdd9c8c41abc2 (diff)
Notes
Diffstat (limited to 'usr.sbin/pkg_install/create')
-rw-r--r--usr.sbin/pkg_install/create/perform.c6
-rw-r--r--usr.sbin/pkg_install/create/pl.c32
2 files changed, 25 insertions, 13 deletions
diff --git a/usr.sbin/pkg_install/create/perform.c b/usr.sbin/pkg_install/create/perform.c
index 8d073e45304e..0c32ea61096f 100644
--- a/usr.sbin/pkg_install/create/perform.c
+++ b/usr.sbin/pkg_install/create/perform.c
@@ -173,8 +173,10 @@ pkg_perform(char **pkgs)
/* Make first "real contents" pass over it */
check_list(home, &plist);
- (void) umask(022); /* make sure gen'ed directories, files don't have
- group or other write bits. */
+ (void) umask(022); /*
+ * Make sure gen'ed directories, files don't have
+ * group or other write bits.
+ */
/* copy_plist(home, &plist); */
/* mark_plist(&plist); */
diff --git a/usr.sbin/pkg_install/create/pl.c b/usr.sbin/pkg_install/create/pl.c
index fc65560f0d9b..3684def1da57 100644
--- a/usr.sbin/pkg_install/create/pl.c
+++ b/usr.sbin/pkg_install/create/pl.c
@@ -116,8 +116,10 @@ copy_plist(char *home, Package *plist)
dev_t curdir;
maxargs = sysconf(_SC_ARG_MAX);
- maxargs -= 64; /* some slop for the tar cmd text,
- and sh -c */
+ maxargs -= 64; /*
+ * Some slop for the tar cmd text,
+ * and sh -c
+ */
where_args = malloc(maxargs);
if (!where_args) {
cleanup(0);
@@ -132,9 +134,11 @@ copy_plist(char *home, Package *plist)
if (stat(".", &stb) == 0)
curdir = stb.st_dev;
else
- curdir = (dev_t) -1; /* It's ok if this is a valid dev_t;
- this is just a hint for an
- optimization. */
+ curdir = (dev_t) -1; /*
+ * It's ok if this is a valid dev_t;
+ * this is just a hint for an
+ * optimization.
+ */
while (p) {
if (p->type == PLIST_CWD)
@@ -152,11 +156,15 @@ copy_plist(char *home, Package *plist)
if (fexists(fn)) {
if (lstat(fn, &stb) == 0 && stb.st_dev == curdir &&
S_ISREG(stb.st_mode)) {
- /* if we can link it to the playpen, that avoids a copy
- and saves time. */
+ /*
+ * If we can link it to the playpen, that avoids a copy
+ * and saves time.
+ */
if (p->name[0] != '/') {
- /* don't link abspn stuff--it doesn't come from
- local dir! */
+ /*
+ * Don't link abspn stuff--it doesn't come from
+ * local dir!
+ */
if (trylink(fn, p->name) == 0) {
p = p->next;
continue;
@@ -198,8 +206,10 @@ copy_plist(char *home, Package *plist)
sprintf(fn, "%s/%s", mythere ? mythere : where, p->name);
if (lstat(fn, &stb) == 0 && stb.st_dev == curdir &&
S_ISREG(stb.st_mode)) {
- /* if we can link it to the playpen, that avoids a copy
- and saves time. */
+ /*
+ * If we can link it to the playpen, that avoids a copy
+ * and saves time.
+ */
if (trylink(fn, p->name) == 0) {
p = p->next;
continue;