summaryrefslogtreecommitdiff
path: root/gnu/usr.bin/binutils/gdb/remote-fileio.c
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/usr.bin/binutils/gdb/remote-fileio.c')
-rw-r--r--gnu/usr.bin/binutils/gdb/remote-fileio.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/gnu/usr.bin/binutils/gdb/remote-fileio.c b/gnu/usr.bin/binutils/gdb/remote-fileio.c
index 281872ec6c0..4593ac0cf08 100644
--- a/gnu/usr.bin/binutils/gdb/remote-fileio.c
+++ b/gnu/usr.bin/binutils/gdb/remote-fileio.c
@@ -181,11 +181,11 @@ remote_fileio_mode_to_target (mode_t mode)
{
mode_t tmode = 0;
- if (mode & S_IFREG)
+ if (S_ISREG(mode))
tmode |= FILEIO_S_IFREG;
- if (mode & S_IFDIR)
+ if (S_ISDIR(mode))
tmode |= FILEIO_S_IFDIR;
- if (mode & S_IFCHR)
+ if (S_ISCHR(mode))
tmode |= FILEIO_S_IFCHR;
if (mode & S_IRUSR)
tmode |= FILEIO_S_IRUSR;