fixed time capsule mount timeout

Set the volume_open timeout to 20 seconds to allow an idle time
capsule disk to spin up.
This commit is contained in:
Simon Vetter 2013-03-13 12:15:34 -07:00
parent 93d871128c
commit ec7b7475ab
5 changed files with 8 additions and 8 deletions

View File

@ -3,9 +3,6 @@ These are known bugs in afpfs-ng 0.8:
- this code definitely needs more testing...
- mounting a time capsule can result in a timeout while the disk starts spinning.
(mine takes more than 10 seconds to spin up). Retrying right after always succeeds.
- if afpfsd isnt' running, and you run an 'afp_client exit', it restarts it
and then kills it

View File

@ -30,6 +30,9 @@ int dsi_recv(struct afp_server * server);
#define DSI_BLOCK_TIMEOUT -1
#define DSI_DONT_WAIT 0
#define DSI_DEFAULT_TIMEOUT 5
//a spun down time capsule can take up to 20 secs to
//wake up and reply to a mount request
#define DSI_OPENVOLUME_TIMEOUT 20
#endif

View File

@ -184,7 +184,7 @@ int afp_volopen(struct afp_volume * volume,
}
ret=dsi_send(volume->server, (char *) msg,len,
DSI_DEFAULT_TIMEOUT,afpOpenVol,(void *) &volume);
DSI_OPENVOLUME_TIMEOUT,afpOpenVol,(void *) &volume);
free(msg);
return ret;