exit on timeout error
This commit is contained in:
parent
a413f33126
commit
0890d32e70
6
ftpfs.c
6
ftpfs.c
|
@ -222,6 +222,12 @@ static int op_return(int err, char * operation)
|
|||
return 0;
|
||||
}
|
||||
fprintf(stderr, "ftpfs: operation %s failed because %s\n", operation, strerror(-err));
|
||||
if (strstr(error_buf, "timed out") != NULL
|
||||
|| strstr(error_buf, "timeout") != NULL
|
||||
|| strstr(error_buf, "time-out") != NULL) {
|
||||
// try to match any curl error which would indiciate that the mount is offline.
|
||||
fuse_exit(fuse_get_context()->fuse);
|
||||
}
|
||||
return err;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue