(no commit message)
authorcristy <urban-warrior@git.imagemagick.org>
Tue, 14 Jan 2014 17:02:30 +0000 (17:02 +0000)
committercristy <urban-warrior@git.imagemagick.org>
Tue, 14 Jan 2014 17:02:30 +0000 (17:02 +0000)
Magick++/lib/Image.cpp

index e9c628135e647f4446966839d18fbaaf17b67357..280b75bde0994deec89a5c1733eac3980ddf8d78 100644 (file)
@@ -2296,7 +2296,10 @@ void Magick::Image::colorMap(const size_t index_,const Color &color_)
 Magick::Color Magick::Image::colorMap(const size_t index_) const
 {
   if (!constImage()->colormap)
-    throwExceptionExplicit(OptionError,"Image does not contain a colormap");
+    {
+      throwExceptionExplicit(OptionError,"Image does not contain a colormap");
+      return(Color());
+    }
 
   if (index_ > constImage()->colors-1)
     throwExceptionExplicit(OptionError,"Index out of range");