aboutsummaryrefslogtreecommitdiff
path: root/toys/toysh.c
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2008-02-12 19:05:44 -0600
committerRob Landley <rob@landley.net>2008-02-12 19:05:44 -0600
commit0f8c4c5998317e575f1afd47dad7f6967bc271ab (patch)
tree11613ae34f3830bf02914c9381eaa5790da63801 /toys/toysh.c
parent6882ee89dc5da4081d5721706ad77a3e0396b1bc (diff)
downloadtoybox-0f8c4c5998317e575f1afd47dad7f6967bc271ab.tar.gz
Add TOYFLAG_UMASK.
Diffstat (limited to 'toys/toysh.c')
-rw-r--r--toys/toysh.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/toys/toysh.c b/toys/toysh.c
index e2800681..17467fad 100644
--- a/toys/toysh.c
+++ b/toys/toysh.c
@@ -296,6 +296,7 @@ static void run_pipeline(struct pipeline *line)
tl->toy_main();
cmd->pid = toys.exitval;
free(toys.optargs);
+ if (toys.old_umask) umask(toys.old_umask);
memcpy(&toys, &temp, sizeof(struct toy_context));
} else {
int status;