+ // Make the process a leader of its own process group, so that we can easily
+ // kill it and any of its child processes (unless it's started new process
+ // groups itself, of course).
+ posix_spawnattr_t attr;
+ posix_spawnattr_init(&attr);
+ posix_spawnattr_setflags(&attr, POSIX_SPAWN_SETPGROUP);
+ posix_spawnattr_setpgroup(&attr, 0);
+