Uploaded image for project: 'Commons Imaging'
  1. Commons Imaging
  2. IMAGING-131

PngImageParser#getBufferedImage() doesn't respect ImageParser specification

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Critical
    • Resolution: Fixed
    • 1.0-alpha1
    • 1.0-alpha1
    • Format: PNG

    Description

      ImageParser#getBufferedImage() specification tell in documentation :

      ImageParser#getBufferedImage()
      /**
         ...
           * @param params     Optional instructions for special-handling or
           *                   interpretation of the input data (null objects are permitted and
           *                   must be supported by implementations).
            ...
           **/
      

      Implementation PngImageParser#getBufferedImage() does note respect this documentation. Indeed, first line of the function is :

      PngImageParser#getBufferedImage() line 637
      if (params.containsKey(PARAM_KEY_VERBOSE)) {
                  params.remove(PARAM_KEY_VERBOSE);
              }
      

      I suppose It would be

      FIX PngImageParser#getBufferedImage()
      if (params!=null && params.containsKey(PARAM_KEY_VERBOSE)) {
                  params.remove(PARAM_KEY_VERBOSE);
              }
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            fasar fasar
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - 1h
                1h
                Remaining:
                Remaining Estimate - 1h
                1h
                Logged:
                Time Spent - Not Specified
                Not Specified