Please fill in the blanks. Each blank is worth 5 points. There are several reasonable answers for some of the blanks; choose one. Blanks with the same number have the same answer.
exec, all ____(user) memory____ is replaced, and the only things that are preserved are the open ____file descriptors/files____ and the ____environment____ variables for the process. In particular, it is impossible to institute a signal ____handler____ before an
execand have it apply to the process after the
int p;. Once the pipe is initialized, one writes to p[____1____] and reads from p[____0____]. To write to a pipe as if it were a terminal or file, one uses the library function ____fdopen____ to make
fprintfwork on the pipe. The differences between
writeacts on a file ____descriptor____ while
fprintfacts on a file ____pointer/buffer____. While
writealways happens ____immediately/when invoked____,
fprintfis ____buffered____ and must be ____flushed____ to ensure that everything is written.
execare different calls is that one often wants to make changes in process settings ____before____ executing the forked process.
typedefs allows one to define shorthands for complex types. For example, after writing
typedef int foo;the typedef declaration ____foo bar;____ declares an array
barwith 10 elements. A typedef cannot be ____repeated____ in the same file.