From: Hyunchul Lee Date: Sun, 14 Jun 2026 23:49:52 +0000 (+0900) Subject: ntfs: fix incorrect size of symbolic link X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=05a5ff86a7f12c861e3516d3dc4d092ce620742d;p=thirdparty%2Fkernel%2Flinux.git ntfs: fix incorrect size of symbolic link This patch fixes the issue where a symbolic link size is displayed as 0. Cc: stable@vger.kernel.org # v7.1 Signed-off-by: Hyunchul Lee Signed-off-by: Namjae Jeon --- diff --git a/fs/ntfs/inode.c b/fs/ntfs/inode.c index 2f2634baa285..efb34a5e94d9 100644 --- a/fs/ntfs/inode.c +++ b/fs/ntfs/inode.c @@ -1199,6 +1199,9 @@ no_data_attr_special_case: else vi->i_blocks = ni->allocated_size >> 9; + if (S_ISLNK(vi->i_mode) && ni->target) + vi->i_size = strlen(ni->target); + ntfs_debug("Done."); return 0; unm_err_out: