]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
vfs_gpfs: Check error from gpfswrap_lib_init
authorChristof Schmitt <cs@samba.org>
Wed, 31 May 2023 18:16:19 +0000 (11:16 -0700)
committerStefan Metzmacher <metze@samba.org>
Sun, 25 Jun 2023 15:09:34 +0000 (15:09 +0000)
Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
source3/modules/vfs_gpfs.c

index 93748eab54c01a86428e46b1ff94142c36f930b8..c4402146bccc9d5c7af0b2465c8e4683e97d429e 100644 (file)
@@ -2041,7 +2041,12 @@ static int vfs_gpfs_connect(struct vfs_handle_struct *handle,
                return 0;
        }
 
-       gpfswrap_lib_init(0);
+       ret = gpfswrap_lib_init(0);
+       if (ret < 0) {
+               DBG_ERR("Could not open GPFS device file: %s\n",
+                       strerror(errno));
+               return ret;
+       }
 
        ret = gpfswrap_register_cifs_export();
        if (ret < 0) {