Skip to content

Commit 1758cd2

Browse files
Alexey Dobriyanjankara
authored andcommitted
fanotify: delete useless parenthesis in FANOTIFY_INLINE_FH macro
Parenthesis around identifier name in declaration are useless. This is just "put every macro argument inside parenthesis" practice. Now "size" must be constant expression, but using comma expression in constant expression is useless too, therefore [] will guard "size" expression just as well as (). Also g++ is somewhat upset about these: fs/notify/fanotify/fanotify.h:278:28: warning: unnecessary parentheses in declaration of ‘object_fh’ [-Wparentheses] 278 | struct fanotify_fh (name); Signed-off-by: Alexey Dobriyan <[email protected]> Signed-off-by: Jan Kara <[email protected]> Message-Id: <633c251a-b548-4428-9e91-1cf8147d8c55@p183>
1 parent 8a749fd commit 1758cd2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

fs/notify/fanotify/fanotify.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -275,9 +275,9 @@ static inline void fanotify_init_event(struct fanotify_event *event,
275275

276276
#define FANOTIFY_INLINE_FH(name, size) \
277277
struct { \
278-
struct fanotify_fh (name); \
278+
struct fanotify_fh name; \
279279
/* Space for object_fh.buf[] - access with fanotify_fh_buf() */ \
280-
unsigned char _inline_fh_buf[(size)]; \
280+
unsigned char _inline_fh_buf[size]; \
281281
}
282282

283283
struct fanotify_fid_event {

0 commit comments

Comments
 (0)