diff options
| author | ChenXiaoSong <chenxiaosong@kylinos.cn> | 2026-08-04 18:42:05 -0500 |
|---|---|---|
| committer | Paulo Alcantara <pc@manguebit.org> | 2026-08-19 12:30:57 -0300 |
| commit | 77d852c76342ff4922f7fabef465cc5d012ab0a7 (patch) | |
| tree | d86305c1472c2fcb8a2e8a8a9ad638bf6d136e7f /include | |
| parent | 60be95527bc8d1b33dca25d2a849268cca11d139 (diff) | |
smb/client: fix nlink of an overwritten open file
Reproducer:
1. server: systemctl start ksmbd
2. client: mount with `posix` option
mount -t cifs -o posix //${server_ip}/export /mnt
3. client: touch /mnt/file1 /mnt/file2
4. client: C program: int fd = open("/mnt/file2", O_RDONLY);
5. client: C program: rename("/mnt/file1", "/mnt/file2");
6. client: C program: struct stat stbuf; fstat(fd, &stbuf);
stbuf.st_nlink is 1, should be 0
This patch fixes xfstests generic/035 when mounted with `posix` option.
Signed-off-by: ChenXiaoSong <chenxiaosong@kylinos.cn>
Signed-off-by: Steve French <stfrench@microsoft.com>
Signed-off-by: Namjae Jeon <linkinjeon@kernel.org>
Signed-off-by: Paulo Alcantara <pc@manguebit.org>
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions
