From: cristy Date: Sun, 8 Jan 2012 21:52:15 +0000 (+0000) Subject: (no commit message) X-Git-Tag: 7.0.1-0~6423 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3b2b171825e9ae17f80d349a77cec5edb3277cd1;p=imagemagick --- diff --git a/MagickCore/attribute.c b/MagickCore/attribute.c index da50c4baa..0c71ee840 100644 --- a/MagickCore/attribute.c +++ b/MagickCore/attribute.c @@ -364,7 +364,7 @@ MagickExport size_t GetImageDepth(const Image *image,ExceptionInfo *exception) ThrowFatalException(ResourceLimitFatalError,"MemoryAllocationFailed"); for (i=0; i <= (ssize_t) MaxMap; i++) { - size_t + unsigned int depth; for (depth=1; depth < MAGICKCORE_QUANTUM_DEPTH; depth++) @@ -479,15 +479,11 @@ MagickExport size_t GetImageDepth(const Image *image,ExceptionInfo *exception) continue; while (current_depth[id] < MAGICKCORE_QUANTUM_DEPTH) { - MagickStatusType - status; - QuantumAny range; range=GetQuantumRange(current_depth[id]); - status=p[i] != ScaleAnyToQuantum(ScaleQuantumToAny(p[i],range),range); - if (status == 0) + if (p[i] == ScaleAnyToQuantum(ScaleQuantumToAny(p[i],range),range)) break; current_depth[id]++; }