vfs_gpfs: remove ENOSYS fallback from vfs_gpfs_fntimes()
authorRalph Boehme <slow@samba.org>
Fri, 13 Aug 2021 09:55:16 +0000 (11:55 +0200)
committerRalph Boehme <slow@samba.org>
Thu, 26 Aug 2021 19:18:31 +0000 (19:18 +0000)
BUG: https://bugzilla.samba.org/show_bug.cgi?id=14771

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Christof Schmitt <cs@samba.org>
source3/modules/vfs_gpfs.c

index a3e725f0fd8d20e3e3b6e5c45dd29cdbfed2a43f..1f5fdadc9c50cdabf5a270a424113f61e9a98371 100644 (file)
@@ -1733,8 +1733,7 @@ static int smbd_gpfs_set_times(struct files_struct *fsp,
        }
 
        rc = gpfswrap_set_times(fsp_get_io_fd(fsp), flags, gpfs_times);
-
-       if (rc != 0 && errno != ENOSYS) {
+       if (rc != 0) {
                DBG_WARNING("gpfs_set_times() returned with error %s for %s\n",
                            strerror(errno),
                            fsp_str_dbg(fsp));
@@ -1759,10 +1758,7 @@ static int vfs_gpfs_fntimes(struct vfs_handle_struct *handle,
 
        /* Try to use gpfs_set_times if it is enabled and available */
        if (config->settimes) {
-               ret = smbd_gpfs_set_times(fsp, ft);
-               if (ret == 0 || (ret == -1 && errno != ENOSYS)) {
-                       return ret;
-               }
+               return smbd_gpfs_set_times(fsp, ft);
        }
 
        DBG_DEBUG("gpfs_set_times() not available or disabled, "