question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

System.OverflowException accessing profile from specific JPG

See original GitHub issue

Description

A user submitted an image to us which we failed to load. We were using Magick.NET 7.14.03, but I have verified the problem still occurs with 7.14.2.0.

The image is attached. “Exported from darktable”, according to our user.

Steps to Reproduce

Our code (distilled):

var settings = new MagickReadSettings();
var imgM = new MagickImage(filename, settings);
var profile = imgM.GetExifProfile();
var exifTag = profile.GetValue(ExifTag.Orientation);

At the profile.GetValue() call, we get a System.OverflowException: Array dimensions exceeded supported range. Examining profile in the debugger, profile.Data is a {byte[38758]} entity:

image

Call stack: image

System Configuration

  • Magick.NET version: 7.14.0.3 / 7.14.2.0
  • Environment (Operating system, version and so on): Win10.1803, x64,
  • Additional information: The image in question.

63210124-7b98c300-c0ea-11e9-9bc2-1860e9b21339.zip

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:1
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
dlemstracommented, Aug 25, 2019

The new release has been published

0reactions
dlemstracommented, Mar 28, 2020

Can you share an image that can be used to reproduce that issue @forresthopkinsa? Could also be an incorrect file.

Read more comments on GitHub >

github_iconTop Results From Across the Web

System.OverflowException When Accessing ImageMagick. ...
OverflowException is being thrown when accessing the ImageMagick. ... This particular image from the screenshot below is a 6.3 MB jpg file.
Read more >
OverflowException occurs when the Async Image load ...
It results in using this image in both UI (when an item is painted) and background threads and leads to the exception. The...
Read more >
Schema Retrieval Results in Error - Microsoft Q&A
My connection works fine in ADF, however when attempting to retrieve table schemas, I receive a "Arithmetic operation resulted in an overflow." ...
Read more >
System.OverflowException while Editing large size images ...
I have to draw Lozenge & text inside Lozenge in image with specific coordinates given by user. I have succeeded to do this...
Read more >
magick Issue Tracker Rss Feed
I'm using Magick.net in a very high volume multi threaded photo processing ... System.OverflowException: Arithmetic operation resulted in an overflow.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found