ImageMagick 7.0.8-34 has a memory leak vulnerability in the WriteDPXImage function in coders/dpx.c.
### Prerequisites

- [ Y  ] I have written a descriptive issue title
- [ Y ] I have verified that I am using the latest version of ImageMagick
- [ Y ] I have searched [open](https://github.com/ImageMagick/ImageMagick/issues) and [closed](https://github.com/ImageMagick/ImageMagick/issues?q=is%3Aissue+is%3Aclosed) issues to ensure it has not already been reported

### Description
<!-- A description of the bug or feature -->
There is a possible but rare memory leak in function `WriteDPXImage` in coders/dpx.c.

```
  pixels=(unsigned char *) GetQuantumPixels(quantum_info);
  for (y=0; y < (ssize_t) image->rows; y++)
  {
    p=GetVirtualPixels(image,0,y,image->columns,1,exception);
    if (p == (const Quantum *) NULL)
      break;
    (void) ExportQuantumPixels(image,(CacheView *) NULL,quantum_info,
      quantum_type,pixels,exception);
    count=WriteBlob(image,extent,pixels);
    if (count != (ssize_t) extent)
      break;
    status=SetImageProgress(image,SaveImageTag,(MagickOffsetType) y,
      image->rows);
    if (status == MagickFalse)
      break;
  }
  quantum_info=DestroyQuantumInfo(quantum_info);
  (void) CloseBlob(image);
  return(status);
```

We should call `ThrowWriterException(CorruptImageError,"UnableToWriteImageData");` when condition `y < (ssize_t) image->rows` satisfies behind for-loop.

See commit https://github.com/ImageMagick/ImageMagick/commit/f1cc2eb986dc8f4a7727bce689a17566f896fde6 for more details.



Possible but rare memory leak in function WriteDPXImage
This is a GitHub Issue
repo:ImageMagick
owner:ImageMagick
Title : Possible but rare memory leak in function WriteDPXImage
Issue date:

--- start body ---
### Prerequisites

- [ Y  ] I have written a descriptive issue title
- [ Y ] I have verified that I am using the latest version of ImageMagick
- [ Y ] I have searched [open](https://github.com/ImageMagick/ImageMagick/issues) and [closed](https://github.com/ImageMagick/ImageMagick/issues?q=is%3Aissue+is%3Aclosed) issues to ensure it has not already been reported

### Description
<!-- A description of the bug or feature -->
There is a possible but rare memory leak in function `WriteDPXImage` in coders/dpx.c.

```
  pixels=(unsigned char *) GetQuantumPixels(quantum_info);
  for (y=0; y < (ssize_t) image->rows; y++)
  {
    p=GetVirtualPixels(image,0,y,image->columns,1,exception);
    if (p == (const Quantum *) NULL)
      break;
    (void) ExportQuantumPixels(image,(CacheView *) NULL,quantum_info,
      quantum_type,pixels,exception);
    count=WriteBlob(image,extent,pixels);
    if (count != (ssize_t) extent)
      break;
    status=SetImageProgress(image,SaveImageTag,(MagickOffsetType) y,
      image->rows);
    if (status == MagickFalse)
      break;
  }
  quantum_info=DestroyQuantumInfo(quantum_info);
  (void) CloseBlob(image);
  return(status);
```

We should call `ThrowWriterException(CorruptImageError,"UnableToWriteImageData");` when condition `y < (ssize_t) image->rows` satisfies behind for-loop.

See commit https://github.com/ImageMagick/ImageMagick/commit/f1cc2eb986dc8f4a7727bce689a17566f896fde6 for more details.



--- end body ---
