From: Cristy Date: Fri, 9 Mar 2018 02:19:07 +0000 (-0500) Subject: Special case for a depth of 0 X-Git-Tag: 7.0.7-26~67 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=73f767950e65cd9a237ac98e7399c479342aee6e;p=imagemagick Special case for a depth of 0 --- diff --git a/MagickCore/quantum-private.h b/MagickCore/quantum-private.h index ce5f1a88a..405c3810e 100644 --- a/MagickCore/quantum-private.h +++ b/MagickCore/quantum-private.h @@ -95,6 +95,8 @@ static inline MagickSizeType GetQuantumRange(const size_t depth) MagickSizeType one; + if (depth == 0) + return(0); one=1; return((MagickSizeType) ((one << (MagickMin(depth,64)-1))+ ((one << (MagickMin(depth,64)-1))-1)));