From c660f531fb4bd9b7f9e108541324be36cb5f4012 Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Tue, 24 Oct 2017 22:29:05 +0200 Subject: [FUSE] Spacing; Don't check if server proto is newer than client The server is always backwards compatible, and so should be the client. If support for an older version will not be kept up, MIN_SUPPORTED_{CLIENT,SERVER} will be increased accordingly so that the connection is dropped. --- src/fuse/connection.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/fuse') diff --git a/src/fuse/connection.c b/src/fuse/connection.c index 29ac2de..f2befae 100644 --- a/src/fuse/connection.c +++ b/src/fuse/connection.c @@ -199,7 +199,7 @@ uint64_t connection_getImageSize() bool connection_read(dnbd3_async_t *request) { - if (!connectionInitDone) return false; + if ( !connectionInitDone ) return false; pthread_mutex_lock( &connection.sendMutex ); enqueueRequest( request ); if ( connection.sockFd != -1 ) { @@ -296,7 +296,7 @@ static void* connection_receiveThreadMain(void *sockPtr) { int sockFd = (int)(size_t)sockPtr; dnbd3_reply_t reply; - pthread_detach(pthread_self()); + pthread_detach( pthread_self() ); while ( keepRunning ) { int ret; @@ -502,7 +502,7 @@ static void probeAltServers() logadd( LOG_DEBUG1, "<- select fail" ); goto fail; } - if ( remoteProto < MIN_SUPPORTED_SERVER || remoteProto > PROTOCOL_VERSION ) { + if ( remoteProto < MIN_SUPPORTED_SERVER ) { logadd( LOG_WARNING, "Unsupported remote version (local: %d, remote: %d)", (int)PROTOCOL_VERSION, (int)remoteProto ); srv->consecutiveFails += 10; goto fail; -- cgit v1.2.3-55-g7522