From: Tobias Tschinkowitz Date: Thu, 24 May 2018 10:09:26 +0000 (+0200) Subject: ram: fixed int overflow on pagetok macro X-Git-Url: https://git.atheridis.org/?a=commitdiff_plain;h=5db729fedbc4b6cb8742c58ff4934afb50732974;p=suckless%2Fslstatus.git ram: fixed int overflow on pagetok macro --- diff --git a/components/ram.c b/components/ram.c index 0ac9753..0333b3b 100644 --- a/components/ram.c +++ b/components/ram.c @@ -75,7 +75,7 @@ #include #define LOG1024 10 - #define pagetok(size, pageshift) ((size) << (pageshift - LOG1024)) + #define pagetok(size, pageshift) (size_t)(size << (pageshift - LOG1024)) inline int load_uvmexp(struct uvmexp *uvmexp)