(is_exe): simple refactoring.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
Andrew Borodin 2021-05-16 12:09:12 +03:00
parent de16ae9180
commit 07837de33b
1 changed files with 1 additions and 1 deletions

View File

@ -282,7 +282,7 @@ exist_file (const char *name)
static inline gboolean
is_exe (mode_t mode)
{
return (gboolean) ((S_IXUSR & mode) || (S_IXGRP & mode) || (S_IXOTH & mode));
return ((mode & (S_IXUSR | S_IXGRP | S_IXOTH)) != 0);
}
#endif /* MC_UTIL_H */