X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=blobdiff_plain;f=server.c;h=f92ef5518cd507ea5e1ef6026e03f841f4b37e37;hp=36af088ec64e0b4fd2baac06cd773653858853f0;hb=1cccf6fa93c251f8f2805aa5fb163741d851c051;hpb=d9e05a6585d795e44847608a8a6ee424a7604b74 diff --git a/server.c b/server.c index 36af088e..f92ef551 100644 --- a/server.c +++ b/server.c @@ -63,9 +63,15 @@ * - Forward error correction: \ref fec.c. */ +#include +#include #include #include #include +#include +#include +#include +#include #include "para.h" #include "error.h" @@ -388,6 +394,9 @@ static int command_post_select(struct sched *s, struct task *t) goto out; } if (child_pid) { + /* avoid problems with non-fork-safe PRNGs */ + unsigned char buf[16]; + get_random_bytes_or_die(buf, sizeof(buf)); close(new_fd); /* parent keeps accepting connections */ return 0;