summaryrefslogtreecommitdiffstats
path: root/xlators
diff options
context:
space:
mode:
Diffstat (limited to 'xlators')
-rw-r--r--xlators/features/snapview-server/src/snapview-server.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/xlators/features/snapview-server/src/snapview-server.c b/xlators/features/snapview-server/src/snapview-server.c
index b7c04bafec7..f209edd2e94 100644
--- a/xlators/features/snapview-server/src/snapview-server.c
+++ b/xlators/features/snapview-server/src/snapview-server.c
@@ -1241,7 +1241,6 @@ svs_glfs_readdir (xlator_t *this, glfs_fd_t *glfd, gf_dirent_t *entries,
GF_VALIDATE_OR_GOTO ("svs", this, out);
GF_VALIDATE_OR_GOTO (this->name, glfd, out);
GF_VALIDATE_OR_GOTO (this->name, entries, out);
- GF_VALIDATE_OR_GOTO (this->name, buf, out);
while (filled_size < size) {
in_case = glfs_telldir (glfd);
@@ -1282,9 +1281,10 @@ svs_glfs_readdir (xlator_t *this, glfs_fd_t *glfd, gf_dirent_t *entries,
entry->d_off = glfs_telldir (glfd);
entry->d_ino = de.d_ino;
entry->d_type = de.d_type;
- iatt_from_stat (buf, &statbuf);
- if (readdirplus)
+ if (readdirplus) {
+ iatt_from_stat (buf, &statbuf);
entry->d_stat = *buf;
+ }
list_add_tail (&entry->list, &entries->list);
filled_size += this_size;