Changes

351 bytes added ,  21:25, 22 September 2009
Line 13: Line 13:  
# now call script that will access die() and $WWWJAIL
 
# now call script that will access die() and $WWWJAIL
 
/etc/nixcraft/setupjail -d cyberciti.com</source>
 
/etc/nixcraft/setupjail -d cyberciti.com</source>
 +
* However, environment variables (such as $HOME, $MAIL etc) are passed to subshell.
 +
==Use exec command to avoid subshell==
 +
You can use the [[exec command]] to avoid subshell. The exec command replaces this shell with the specified program. For example,
 +
<source lang="bash">exec command
 +
# redirect the shells stderr to null
 +
exec 2>/dev/null</source>
 +
 
[[Category:Catching signals]][[Category:Commands]]
 
[[Category:Catching signals]][[Category:Commands]]