Only drop privileges after we've bound to port

This commit is contained in:
Juhani Krekelä 2018-07-11 18:06:00 +00:00
parent 386df61f16
commit 70c3403c6f
1 changed files with 1 additions and 1 deletions

View File

@ -197,8 +197,8 @@ void handle_connection(int sock) {
}
int main(void) {
drop_privileges();
setup_listen();
drop_privileges();
for(;;) {
int amount_ready = poll(listens, num_listens, -1);