native: set _native_pid correctly in daemon mode

This fixes a bug that leads to all unix sockets being created as
`/tmp/riot.tty.0`.
This commit is contained in:
Ludwig Ortmann 2014-05-19 19:58:05 +02:00
parent 05a3570ffe
commit c9f68e79b9

View File

@ -146,6 +146,9 @@ void daemonize(void)
real_printf("RIOT pid: %d\n", _native_pid);
exit(EXIT_SUCCESS);
}
else {
_native_pid = real_getpid();
}
}
void usage_exit(void)