Skip to content

Commit

Permalink
Merge pull request #33 from jamesodhunt/cleanup-duplicate-perms-code
Browse files Browse the repository at this point in the history
cleanup: Remove duplicated perms code
  • Loading branch information
jamesodhunt authored Nov 9, 2024
2 parents af5a866 + cbb6269 commit f62c749
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 14 deletions.
7 changes: 0 additions & 7 deletions src/platform/linux/platform.c
Original file line number Diff line number Diff line change
Expand Up @@ -586,13 +586,6 @@ show_fds_linux (void)
die("failed to allocate space for permissions string");
perms = (st.st_mode & ~S_IFMT);

if (perms & S_ISUID)
modestr[3] = 's';
if (perms & S_ISGID)
modestr[6] = 's';
if (perms & S_ISVTX)
modestr[9] = 't';

section_open("permissions");

entry("octal", "%4.4o", perms);
Expand Down
7 changes: 0 additions & 7 deletions src/procenv.c
Original file line number Diff line number Diff line change
Expand Up @@ -1920,13 +1920,6 @@ show_stat (void)
die ("failed to allocate space for permissions string");
perms = (st.st_mode & ~S_IFMT);

if (perms & S_ISUID)
modestr[3] = 's';
if (perms & S_ISGID)
modestr[6] = 's';
if (perms & S_ISVTX)
modestr[9] = 't';

section_open ("permissions");

entry ("octal", "%4.4o", perms);
Expand Down

0 comments on commit f62c749

Please sign in to comment.