cifs: Fix check for regular file in couldbe_mf_symlink()
[cascardo/linux.git] / fs / cifs / link.c
index 52f41f9..264ece7 100644 (file)
@@ -185,7 +185,7 @@ format_mf_symlink(u8 *buf, unsigned int buf_len, const char *link_str)
 bool
 couldbe_mf_symlink(const struct cifs_fattr *fattr)
 {
-       if (!(fattr->cf_mode & S_IFREG))
+       if (!S_ISREG(fattr->cf_mode))
                /* it's not a symlink */
                return false;