]> andersk Git - moira.git/blobdiff - clients/lib/utils.c
fix bugs in mr_version fallback handling
[moira.git] / clients / lib / utils.c
index ec6ebab4d4d2fbcd05ee01f7339aef3d6951e696..e6ad96e244a4beaa019f2c72412a4c3d42edb2a9 100644 (file)
@@ -54,9 +54,9 @@ int mrcl_connect(char *server, char *client, int version, int auth)
       if (status == MR_UNKNOWN_PROC)
        {
          if (version > 2)
-           status == MR_VERSION_HIGH;
+           status = MR_VERSION_HIGH;
          else
-           status == MR_SUCCESS;
+           status = MR_SUCCESS;
        }
 
       if (status == MR_VERSION_HIGH)
@@ -64,7 +64,7 @@ int mrcl_connect(char *server, char *client, int version, int auth)
          com_err(whoami, 0, "Warning: This client is running newer code than the server.");
          com_err(whoami, 0, "Some operations may not work.");
        }
-      else if (status != MR_VERSION_LOW)
+      else if (status && status != MR_VERSION_LOW)
        {
          com_err(whoami, status, "while setting query version number.");
          mr_disconnect();
This page took 0.035477 seconds and 4 git commands to generate.