From: Christof Schmitt Date: Wed, 31 May 2023 18:16:19 +0000 (-0700) Subject: vfs_gpfs: Check error from gpfswrap_lib_init X-Git-Tag: talloc-2.4.1~255 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=25e1e487a5f32ec5ae3cd8e9f49535eae0358e88;p=thirdparty%2Fsamba.git vfs_gpfs: Check error from gpfswrap_lib_init Signed-off-by: Christof Schmitt Reviewed-by: Stefan Metzmacher --- diff --git a/source3/modules/vfs_gpfs.c b/source3/modules/vfs_gpfs.c index 93748eab54c..c4402146bcc 100644 --- a/source3/modules/vfs_gpfs.c +++ b/source3/modules/vfs_gpfs.c @@ -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) {