diff options
Diffstat (limited to 'api')
-rw-r--r-- | api/src/glfs-fops.c | 6 | ||||
-rw-r--r-- | api/src/glfs-resolve.c | 1 |
2 files changed, 5 insertions, 2 deletions
diff --git a/api/src/glfs-fops.c b/api/src/glfs-fops.c index 7cb442b5f60..3aa8ab834fa 100644 --- a/api/src/glfs-fops.c +++ b/api/src/glfs-fops.c @@ -136,7 +136,8 @@ out: if (ret && glfd) { glfs_fd_destroy (glfd); glfd = NULL; - } else { + } else if (glfd) { + glfd->fd->flags = flags; fd_bind (glfd->fd); glfs_fd_bind (glfd); } @@ -404,7 +405,8 @@ out: if (ret && glfd) { glfs_fd_destroy (glfd); glfd = NULL; - } else { + } else if (glfd) { + glfd->fd->flags = flags; fd_bind (glfd->fd); glfs_fd_bind (glfd); } diff --git a/api/src/glfs-resolve.c b/api/src/glfs-resolve.c index beb270322eb..1dcaddecd24 100644 --- a/api/src/glfs-resolve.c +++ b/api/src/glfs-resolve.c @@ -613,6 +613,7 @@ glfs_migrate_fd_safe (struct glfs *fs, xlator_t *newsubvol, fd_t *oldfd) goto out; } + newfd->flags = oldfd->flags; fd_bind (newfd); out: if (newinode) |