Gerald Pfeifer : netapi32: Avoid shift overflow for GENERIC_READ_ACCESS and friends. friends.

Alexandre Julliard julliard at wine.codeweavers.com
Mon Sep 14 09:44:34 CDT 2015


Module: wine
Branch: master
Commit: a818d5cab2ebb7ff58b0aaf2ad39aa5374f40f22
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=a818d5cab2ebb7ff58b0aaf2ad39aa5374f40f22

Author: Gerald Pfeifer <gerald at pfeifer.com>
Date:   Fri Sep 11 21:31:12 2015 +0200

netapi32: Avoid shift overflow for GENERIC_READ_ACCESS and friends. friends.

---

 dlls/netapi32/netapi32.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/dlls/netapi32/netapi32.c b/dlls/netapi32/netapi32.c
index d7af2e0..bb61e7f 100644
--- a/dlls/netapi32/netapi32.c
+++ b/dlls/netapi32/netapi32.c
@@ -506,10 +506,10 @@ static unsigned char ace_flags_to_samba( BYTE flags )
     return ret;
 }
 
-#define GENERIC_ALL_ACCESS     (1 << 28)
-#define GENERIC_EXECUTE_ACCESS (1 << 29)
-#define GENERIC_WRITE_ACCESS   (1 << 30)
-#define GENERIC_READ_ACCESS    (1 << 31)
+#define GENERIC_ALL_ACCESS     (1u << 28)
+#define GENERIC_EXECUTE_ACCESS (1u << 29)
+#define GENERIC_WRITE_ACCESS   (1u << 30)
+#define GENERIC_READ_ACCESS    (1u << 31)
 
 static unsigned int access_mask_to_samba( DWORD mask )
 {




More information about the wine-cvs mailing list