]> git.ipfire.org Git - thirdparty/openldap.git/commitdiff
ITS#8989 fix bitshift integer overflow
authorHoward Chu <hyc@symas.com>
Sun, 10 Mar 2019 14:21:48 +0000 (14:21 +0000)
committerHoward Chu <hyc@symas.com>
Sun, 10 Mar 2019 14:21:48 +0000 (14:21 +0000)
servers/slapd/back-mdb/id2entry.c

index 08cac2af6db93af0e5c2b721b1af385ae8cb0063..6682d91407ce9e7c2ee7dde8bbe9d8a9719ba189 100644 (file)
@@ -568,7 +568,7 @@ static int mdb_entry_partsize(struct mdb_info *mdb, MDB_txn *txn, Entry *e,
        return 0;
 }
 
-#define HIGH_BIT (1<<(sizeof(unsigned int)*CHAR_BIT-1))
+#define HIGH_BIT (1U<<(sizeof(unsigned int)*CHAR_BIT-1))
 
 /* Flatten an Entry into a buffer. The buffer starts with the count of the
  * number of attributes in the entry, the total number of values in the