Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NullReferenceException when loading jpeg image #695

Closed
4 tasks done
mabead opened this issue Sep 6, 2018 · 1 comment
Closed
4 tasks done

NullReferenceException when loading jpeg image #695

mabead opened this issue Sep 6, 2018 · 1 comment

Comments

@mabead
Copy link

mabead commented Sep 6, 2018

Prerequisites

  • I have written a descriptive issue title
  • I have verified that I am running the latest version of ImageSharp
  • I have verified if the problem exist in both DEBUG and RELEASE mode
  • I have searched open and closed issues to ensure it has not already been reported

Description

Loading image throws exception.

Steps to Reproduce

With 1.0.0-beta005, calling Image.Load on the attached file throws the following exception:

System.NullReferenceException
  HResult=0x80004003
  Message=Object reference not set to an instance of an object.
  Source=SixLabors.ImageSharp
  StackTrace:
   at SixLabors.ImageSharp.Formats.Jpeg.JpegDecoderCore.SixLabors.ImageSharp.Formats.Jpeg.Components.Decoder.IRawJpegData.get_Components()
   at SixLabors.ImageSharp.Formats.Jpeg.Components.Decoder.JpegImagePostProcessor..ctor(MemoryAllocator memoryAllocator, IRawJpegData rawJpeg)
   at SixLabors.ImageSharp.Formats.Jpeg.JpegDecoderCore.PostProcessIntoImage[TPixel]()
   at SixLabors.ImageSharp.Formats.Jpeg.JpegDecoder.Decode[TPixel](Configuration configuration, Stream stream)
   at SixLabors.ImageSharp.Image.Decode[TPixel](Stream stream, Configuration config)
   at SixLabors.ImageSharp.Image.WithSeekableStream[T](Configuration config, Stream stream, Func`2 action)
   at SixLabors.ImageSharp.Image.Load[TPixel](Configuration config, Stream stream, IImageFormat& format)
   at SixLabors.ImageSharp.Image.Load(Stream stream)
   at LANDR.Distribution.ImageProcessor.PictureProvider.Resize(Stream sourceStream, String target, Int32 newWidth, Int32 newHeight) in C:\git\Distribution\src\LANDR.Distribution.ImageProcessor\PictureProvider.cs:line 81

Here's the file:
i think im in love art 3000pg.zip

System Configuration

  • ImageSharp version: 1.0.0-beta005
  • Other ImageSharp packages and versions:
  • Environment (Operating system, version and so on): windows
  • .NET Framework version: .NET core 2.0
  • Additional information:
@JimBobSquarePants
Copy link
Member

Fixed with #699

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants