mirror of
https://github.com/mmueller41/genode.git
synced 2026-01-21 12:32:56 +01:00
rump: fix compiler warning
Fixes two warnings of this type:
! src/lib/vfs/rump/vfs_rump.cc:214:52: warning: narrowing conversion of
! ‘(s.stat::st_mode & 64)’ from ‘__mode_t’ {aka ‘unsigned int’} to ‘bool’
! [-Wnarrowing]
!
! 214 | .executable = (s.st_mode & S_IXUSR) };
! | ~~~~~~~~~~~^~~~~~~~~~
Fixes #4160
This commit is contained in:
committed by
Christian Helmuth
parent
7b09675236
commit
0069660958
@@ -211,7 +211,7 @@ class Vfs::Rump_file_system : public File_system
|
||||
|
||||
Node_rwx const rwx { .readable = true,
|
||||
.writeable = true,
|
||||
.executable = (s.st_mode & S_IXUSR) };
|
||||
.executable = (s.st_mode & S_IXUSR) != 0 };
|
||||
|
||||
vfs_dir = {
|
||||
.fileno = s.st_ino,
|
||||
@@ -702,7 +702,7 @@ class Vfs::Rump_file_system : public File_system
|
||||
.type = type(sb.st_mode),
|
||||
.rwx = { .readable = true,
|
||||
.writeable = true,
|
||||
.executable = (sb.st_mode & S_IXUSR) },
|
||||
.executable = (sb.st_mode & S_IXUSR) != 0 },
|
||||
.inode = sb.st_ino,
|
||||
.device = sb.st_dev,
|
||||
|
||||
|
||||
Reference in New Issue
Block a user