Since rpc_connect_async sets autoreconnect to 0, turn autoreconnect on
after the connection has completed, not before.
This fixes #76.
Signed-off-by: Ross Lagerwall <rosslagerwall@gmail.com>
return;
}
+ /* NFS TCP connections we want to autoreconnect after sessions are torn down (due to inactivity or error) */
+ rpc_set_autoreconnect(rpc);
+
args.fsroot = nfs->rootfh;
if (rpc_nfs3_fsinfo_async(rpc, nfs_mount_9_cb, &args, data) != 0) {
data->cb(-ENOMEM, nfs, command_data, data->private_data);
free_nfs_cb_data(data);
return;
}
-
- /* NFS TCP connections we want to autoreconnect after sessions are torn down (due to inactivity or error) */
- rpc_set_autoreconnect(rpc);
}