RECONNECT exit from sync event_loop in case of an error

If there is an error during reconnect we should not loop in event_loop
as this will cause a deadlock in case there is actually an error like
connection drop etc. If this reconnect fails the reconnect routine
will retry itself.
This commit is contained in:
Peter Lieven
2012-11-17 12:38:26 +01:00
committed by Ronnie Sahlberg
parent f9dc2da672
commit 577d37c5ed

View File

@@ -54,11 +54,6 @@ event_loop(struct iscsi_context *iscsi, struct iscsi_sync_state *state)
continue;
}
if (iscsi_service(iscsi, pfd.revents) < 0) {
/* if we are reconnecting we just try and try again */
if (iscsi->is_reconnecting) {
continue;
}
iscsi_set_error(iscsi,
"iscsi_service failed with : %s",
iscsi_get_error(iscsi));