Up to [local] / src / usr.bin / bc
Request diff between arbitrary revisions
Default branch: MAIN
Current tag: OPENBSD_6_1_BASE
Revision 1.8 / (download) - annotate - [select for diffs], Sat Oct 10 19:28:54 2015 UTC (8 years, 8 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_6_1_BASE,
OPENBSD_6_1,
OPENBSD_6_0_BASE,
OPENBSD_6_0,
OPENBSD_5_9_BASE,
OPENBSD_5_9
Changes since 1.7: +5 -4 lines
Diff to previous 1.7 (colored)
Rather than invoking fork/execve of dc(1) on a pipe, compile in the dc(1) code directly and use it as a subfunction. This refactoring allows use of pledge "stdio rpath proc tty" in the main bc(1) process before fork, pledge "stdio rpath tty" after fork, and fully reduced to "stdio" in the dc(1) child. This requires two recent to the kernel code (allowing sigsuspend(), and kill() self as pid 0). ok otto