mirror of
https://gitlab.uni-freiburg.de/opensourcevdi/spice
synced 2026-08-18 09:30:06 +00:00
reds_init_net: report errors on watch setup failures
We used to be aborting in such situations, but this was changed during the big spice_error/printerr cleanup. We are currently outputting a warning but not reporting the error with the caller when reds_init_net fails to register listening watches with the mainloop. As it's unlikely that things will work as expected in such cases, better to error out of the function instead of pretending everything is all right.
This commit is contained in:
parent
eb19ac081f
commit
5177c5fd09
@ -3176,6 +3176,7 @@ static int reds_init_net(void)
|
||||
reds_accept, NULL);
|
||||
if (reds->listen_watch == NULL) {
|
||||
spice_warning("set fd handle failed");
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
@ -3190,6 +3191,7 @@ static int reds_init_net(void)
|
||||
reds_accept_ssl_connection, NULL);
|
||||
if (reds->secure_listen_watch == NULL) {
|
||||
spice_warning("set fd handle failed");
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
@ -3200,6 +3202,7 @@ static int reds_init_net(void)
|
||||
reds_accept, NULL);
|
||||
if (reds->listen_watch == NULL) {
|
||||
spice_warning("set fd handle failed");
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user