Calling GetImageColorSpace() on an image mask.

Q: We have encountered an exception when calling GetImageColorSpace()
for an image (object #65) in one PDF. The image is a mask, but the
PDFNet documentation says that the GetImageColorSpace() function
should return Null rather than throw an exception in that case.
A: Because this image is an ImageMask (i.e. image.IsImageMask()
returns true), the image dictionary is not supposed to contain a
ColorSpace entry because sample values represent masking properties (1
bit per sample) rather than colors.

Since the current behavior of the function does not conform to
documentation, we have modified this function to return 'null' instead
of exception. Please keep in mind that you can use image.IsImageMask()
to identify image color mask so that you don't need to call