mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-06 17:48:35 +00:00
[lib] add mising UL qualifier to numerical constant
2008-01-08 Pavol Rusnak <prusnak@suse.cz> * memory.c: (mtype_memstr) Fix accidental shift past width of type, constant should have been forced to UL, rather than being left to default to int.
This commit is contained in:
parent
370b64a2ad
commit
912df1e8ab
@ -1,3 +1,9 @@
|
|||||||
|
2008-01-08 Pavol Rusnak <prusnak@suse.cz>
|
||||||
|
|
||||||
|
* memory.c: (mtype_memstr) Fix accidental shift past width of type,
|
||||||
|
constant should have been forced to UL, rather than being left to
|
||||||
|
default to int.
|
||||||
|
|
||||||
2007-11-12 Denis Ovsienko
|
2007-11-12 Denis Ovsienko
|
||||||
|
|
||||||
* linklist.c: (listnode_add_after) Don't forget to increment list
|
* linklist.c: (listnode_add_after) Don't forget to increment list
|
||||||
|
@ -501,7 +501,7 @@ mtype_memstr (char *buf, size_t len, unsigned long bytes)
|
|||||||
* Just hacked to make it not warn on 'smaller' machines.
|
* Just hacked to make it not warn on 'smaller' machines.
|
||||||
* Static compiler analysis should mean no extra code
|
* Static compiler analysis should mean no extra code
|
||||||
*/
|
*/
|
||||||
if (bytes & (1 << (sizeof (unsigned long) >= 8 ? 39 : 0)))
|
if (bytes & (1UL << (sizeof (unsigned long) >= 8 ? 39 : 0)))
|
||||||
t++;
|
t++;
|
||||||
snprintf (buf, len, "%4d TiB", t);
|
snprintf (buf, len, "%4d TiB", t);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user