From: Nathan Binkert Date: Mon, 4 Aug 2008 01:19:53 +0000 (-0700) Subject: syscall: Avoid a compiler warning which turns into a bug. X-Git-Tag: m5_2.0_beta6~67 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=678abbc3646695f7d9693ce0757abaf7463d0354;p=gem5.git syscall: Avoid a compiler warning which turns into a bug. Simply cast the result to an int and life is good. --- diff --git a/src/sim/syscall_emul.cc b/src/sim/syscall_emul.cc index 3a0db1016..3f6c56b5f 100644 --- a/src/sim/syscall_emul.cc +++ b/src/sim/syscall_emul.cc @@ -385,7 +385,7 @@ umaskFunc(SyscallDesc *desc, int num, LiveProcess *process, ThreadContext *tc) // changing anything. mode_t oldMask = umask(0); umask(oldMask); - return oldMask; + return (int)oldMask; } SyscallReturn