libgfapi : return if gf_strdup failed

Change-Id: Ic8ad48b8118a8505ebbab2e9084007acca7226e9
BUG: 1198963
Signed-off-by: Humble Devassy Chirammal <hchiramm@redhat.com>
Reviewed-on: http://review.gluster.org/9807
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Tested-by: Gluster Build System <jenkins@build.gluster.com>
This commit is contained in:
Humble Devassy Chirammal 2015-03-30 18:59:52 +05:30 committed by Niels de Vos
parent 6d083f47e1
commit 07bd6c320c

View File

@ -733,7 +733,8 @@ pub_glfs_set_volfile (struct glfs *fs, const char *volfile)
return -1;
cmd_args->volfile = gf_strdup (volfile);
if (!cmd_args->volfile)
return -1;
return 0;
}