2024-01-22 18:33:05

by Shrikanth Hegde

[permalink] [raw]
Subject: [RFC PATCH v2 3/4] ntfs: remove duplicate ifdefs

when a ifdef is used in the below manner, second one could be considered as
duplicate.

ifdef DEFINE_A
..code block...
ifdef DEFINE_A
..code block...
endif
..code block...
endif

In the ntfs code, one such pattern was seen. Hence remove that duplicate
ifdef.
No functional change is intended here. It only aims to improve code
readability.

Signed-off-by: Shrikanth Hegde <[email protected]>
---
fs/ntfs/inode.c | 2 --
1 file changed, 2 deletions(-)

diff --git a/fs/ntfs/inode.c b/fs/ntfs/inode.c
index aba1e22db4e9..d2c8622d53d1 100644
--- a/fs/ntfs/inode.c
+++ b/fs/ntfs/inode.c
@@ -2859,11 +2859,9 @@ int ntfs_truncate(struct inode *vi)
*
* See ntfs_truncate() description above for details.
*/
-#ifdef NTFS_RW
void ntfs_truncate_vfs(struct inode *vi) {
ntfs_truncate(vi);
}
-#endif

/**
* ntfs_setattr - called from notify_change() when an attribute is being changed
--
2.39.3