Skip to content

Commit

Permalink
[LibOS] Fix R_OK and X_OK macros for file permissions
Browse files Browse the repository at this point in the history
These macros were mixed up. However, they were used only in the syscall
parser so this mix up didn't lead to any functionality issues. Noticed
when analyzing Gramine logs; kudos to Jinen Gandhi and Anjali Rai.

Signed-off-by: Dmitrii Kuvaiskii <dmitrii.kuvaiskii@intel.com>
  • Loading branch information
dimakuv committed Feb 5, 2024
1 parent 1cf1f46 commit 0546de9
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions libos/include/libos_fs.h
Original file line number Diff line number Diff line change
Expand Up @@ -504,10 +504,10 @@ struct libos_mount {

extern struct libos_dentry* g_dentry_root;

#define F_OK 0
#define R_OK 001
#define W_OK 002
#define X_OK 004
#define F_OK 0
#define X_OK 001
#define W_OK 002
#define R_OK 004
#define MAY_EXEC 001
#define MAY_WRITE 002
#define MAY_READ 004
Expand Down

0 comments on commit 0546de9

Please sign in to comment.