diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/driver/ntux_driver_ctx.c | 8 | ||||
-rw-r--r-- | src/internal/ntux_driver_impl.h | 2 | ||||
-rw-r--r-- | src/skin/ntux_skin_chmod.c | 6 |
3 files changed, 16 insertions, 0 deletions
diff --git a/src/driver/ntux_driver_ctx.c b/src/driver/ntux_driver_ctx.c index 8445b3e..efb1c37 100644 --- a/src/driver/ntux_driver_ctx.c +++ b/src/driver/ntux_driver_ctx.c @@ -232,6 +232,14 @@ static int ntux_cctx_update( cctx->drvflags |= NTUX_DRIVER_CHANGES; break; + case TAG_OWNER: + cctx->owner = entry->arg; + break; + + case TAG_GROUP: + cctx->group = entry->arg; + break; + case TAG_ROOTED: cctx->drvflags &= ~(uint64_t)NTUX_DRIVER_ROOTLESS; cctx->drvflags |= NTUX_DRIVER_ROOTED; diff --git a/src/internal/ntux_driver_impl.h b/src/internal/ntux_driver_impl.h index 06a5c8f..6a7e070 100644 --- a/src/internal/ntux_driver_impl.h +++ b/src/internal/ntux_driver_impl.h @@ -31,6 +31,8 @@ enum app_tags { TAG_STRMODE, TAG_REFMODE, TAG_CHANGES, + TAG_OWNER, + TAG_GROUP, TAG_ROOTED, TAG_ROOTLESS, }; diff --git a/src/skin/ntux_skin_chmod.c b/src/skin/ntux_skin_chmod.c index cb300a6..1aab9c0 100644 --- a/src/skin/ntux_skin_chmod.c +++ b/src/skin/ntux_skin_chmod.c @@ -29,6 +29,12 @@ const struct argv_option ntux_chmod_options[] = { {"changes", 'c',TAG_CHANGES,ARGV_OPTARG_NONE,0,0,0, "a synonym for --refmode"}, + {"owner", 'O',TAG_OWNER,ARGV_OPTARG_REQUIRED,0,0,"<OWNER>", + "also set the owner to %s"}, + + {"group", 'G',TAG_GROUP,ARGV_OPTARG_REQUIRED,0,0,"<GROUP>", + "also set the group to %s"}, + {"preserve-root", 0,TAG_ROOTED,ARGV_OPTARG_NONE,0,0,0, "disallow operating on the root folder /"}, |