NFSv2: Fix a typo in encode_sattr()

Encode the mtime correctly.

Fixes: 95582b0083 ("vfs: change inode times to use struct timespec64")
Signed-off-by: Trond Myklebust <[email protected]>
This commit is contained in:
Trond Myklebust committed 2019-11-03 21:28:44 -05:00
1 parent 7d34ff5141
commit ad97a995d8
1 file changed
+1 -1
+1 -1
View File
@@ -370,7 +370,7 @@ static void encode_sattr(struct xdr_stream *xdr, const struct iattr *attr,
} else
p = xdr_time_not_set(p);
if (attr->ia_valid & ATTR_MTIME_SET) {
ts = timespec64_to_timespec(attr->ia_atime);
ts = timespec64_to_timespec(attr->ia_mtime);
xdr_encode_time(p, &ts);
} else if (attr->ia_valid & ATTR_MTIME) {
ts = timespec64_to_timespec(attr->ia_mtime);