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.

MaxBufferSize is not enough.

See original GitHub issue

Hello.

I got an error, TypeError: Corrupt JPG, exceeded buffer limits, when I use image-size with an JPEG image file. But when I increase the MaxBufferSize in lib/index.js, it works well.

Could you increase the MaxBufferSize?

What I changed to test: var MaxBufferSize = 128*1024 * 100;

This is the sample file: https://www.dropbox.com/s/qvat156gv0nq13b/b95ff27a4b146a0b95cb4d5f58189c4f.jpg?dl=0

Issue Analytics

  • State:open
  • Created 9 years ago
  • Comments:13 (1 by maintainers)

github_iconTop GitHub Comments

4reactions
puzrincommented, Apr 2, 2016

@zeke, you will deal with such “adaptive” kludges forever, until add true streaming support.

See https://github.com/nodeca/probe-image-size. We did it because this package was not supported for a long time. Feel free to reuse as you wish.

0reactions
oliverfostercommented, Apr 2, 2016

I look forward to seeing it when it’s done. Sounds like I could learn a thing of two.

Read more comments on GitHub >

github_iconTop Results From Across the Web

how to make no limit on maxBufferSize and ... - Stack Overflow
The maximum you can set it to is 2 billion ( int.MaxValue in .NET) - which corresponds to 2 GB (2'147'483'648 bytes) of...
Read more >
No maxBufferSize setting for WsHttpBinding - MSDN - Microsoft
Hi,. For this scenario, in fact wsHttpBinding binding does not have any maxBufferSize property. This property is available in basicHttpBinding ...
Read more >
default-threading-profile > maxBufferSize does not work
Any clue why its not working and how can I leverage maxBufferSize? ... Not sure why it doesnt for you. ... So 2...
Read more >
Dynamics AX 2012- maxbuffersize
El intento de insertar un registro con este contenedor no se realizará ... already in some standard features this is not enough.
Read more >
Maximum buffer size - IBM
The maxbuffersize parameter specifies the size of the transmission buffers ... The value should be large enough to accept the largest possible COMMAREA...
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