]> git.proxmox.com Git - mirror_corosync.git/commitdiff
Qnetd: Return errors in test algorithm
authorJan Friesse <jfriesse@redhat.com>
Thu, 2 Jun 2016 14:42:08 +0000 (16:42 +0200)
committerJan Friesse <jfriesse@redhat.com>
Tue, 28 Jun 2016 11:58:42 +0000 (13:58 +0200)
Signed-off-by: Jan Friesse <jfriesse@redhat.com>
qdevices/qnetd-algo-test.c

index 2ff8e7c447ada35c2ceca7dc299665b2c4a0e295..5f9f9c75283e45aceeeef24cf5e18bae97cdd39b 100644 (file)
@@ -75,7 +75,7 @@ qnetd_algo_test_client_init(struct qnetd_client *client)
 
        client->algorithm_data = malloc(sizeof(int));
        if (client->algorithm_data == NULL) {
-               return (-1);
+               return (TLV_REPLY_ERROR_CODE_INTERNAL_ERROR);
        }
 
        algo_data = client->algorithm_data;
@@ -89,7 +89,7 @@ qnetd_algo_test_client_init(struct qnetd_client *client)
 
                client->cluster->algorithm_data = malloc(sizeof(int));
                if (client->cluster->algorithm_data == NULL) {
-                       return (-1);
+                       return (TLV_REPLY_ERROR_CODE_INTERNAL_ERROR);
                }
 
                algo_data = client->cluster->algorithm_data;