Browse Source

fix handling of max buffer sizes in the client

Julius Pfrommer 8 years ago
parent
commit
6d5b9a151a
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/client/ua_client.c

+ 1 - 1
src/client/ua_client.c

@@ -173,9 +173,9 @@ static UA_StatusCode HelAckHandshake(UA_Client *client) {
         conn->remoteConf.maxMessageSize = ackMessage.maxMessageSize; /* may be zero -> unlimited */
         conn->remoteConf.protocolVersion = ackMessage.protocolVersion;
         conn->remoteConf.sendBufferSize = ackMessage.sendBufferSize;
+        conn->remoteConf.recvBufferSize = ackMessage.receiveBufferSize;
         if(conn->remoteConf.recvBufferSize < conn->localConf.sendBufferSize)
             conn->localConf.sendBufferSize = conn->remoteConf.recvBufferSize;
-        conn->remoteConf.recvBufferSize = ackMessage.receiveBufferSize;
         if(conn->remoteConf.sendBufferSize < conn->localConf.recvBufferSize)
             conn->localConf.recvBufferSize = conn->remoteConf.sendBufferSize;
         conn->state = UA_CONNECTION_ESTABLISHED;