compiler warnings.

2 views
Skip to first unread message

Tomas Dalebjörk

unread,
Jan 15, 2026, 5:07:26 PMJan 15
to WinFsp
Hi,

Not that this is important. but to place parentheses surrounding this will keep the compiler quiet.

Regards Tomas

./winfsp/winfsp/winfsp.h(1417,53): warning: '&&' within '||' [-Wlogical-op-parentheses]
        FspFsctlTransactCreateKind == Request->Kind && Request->Req.Create.CaseSensitive ||
        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~
./winfsp/winfsp/winfsp.h(1417,53): note: place parentheses around the '&&' expression to silence this warning
        FspFsctlTransactCreateKind == Request->Kind && Request->Req.Create.CaseSensitive ||

Bill Zissimopoulos

unread,
Jan 16, 2026, 2:31:55 AMJan 16
to Tomas Dalebjörk, WinFsp
Tomas:

Even though the logic is correct here because the multiplicative && operator has higher precedence than the additive || operator I would rather not have warnings at all.

Which compiler are you using and which warning level?

Thanks.

Bill

--
You received this message because you are subscribed to the Google Groups "WinFsp" group.
To unsubscribe from this group and stop receiving emails from it, send an email to winfsp+un...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/winfsp/CACrcyf%2B2uOZkoJJota5%3DGVwZzw%2BCJfw91J-3pXsigczD1zyVbw%40mail.gmail.com.
Reply all
Reply to author
Forward
0 new messages