From: Wolfgang Bumiller Date: Tue, 14 Feb 2017 18:17:45 +0000 (+0100) Subject: sanitize: use 1u (unsigned) for flag bit shifts X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=02586128153fb3b7216345b02fa6ed3e0b1fe023;p=xonotic%2Fgmqcc.git sanitize: use 1u (unsigned) for flag bit shifts Fixes #175 --- diff --git a/opts.c b/opts.c index e50bd74..b880ac2 100644 --- a/opts.c +++ b/opts.c @@ -170,9 +170,9 @@ void opts_set(uint32_t *flags, size_t idx, bool on) { LONGBIT_SET(lb, idx); if (on) - flags[lb.idx] |= (1<<(lb.bit)); + flags[lb.idx] |= (1u<<(lb.bit)); else - flags[lb.idx] &= ~(1<<(lb.bit)); + flags[lb.idx] &= ~(1u<<(lb.bit)); } void opts_setoptimlevel(unsigned int level) {