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

Show error message if reading stream fails #865

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

revmischa
Copy link

It's difficult to debug some errors when the only error message is "Stream yields empty buffer".

This adds stderr to the error message to make it easier to see what's going on.

Before:

Stream yields empty buffer

After:

Error converting pdf to image Error: Stream yields empty buffer
gm convert: "gs" "-q" "-dBATCH" "-dSAFER" "-dMaxBitmap=50000000" "-dNOPAUSE" "-sDEVICE=pnmraw" "-dTextAlphaBits=4" "-dGraphicsAlphaBits=4" "-r200x200" "-sOutputFile=/tmp/gmKaF5ew" "--" "/tmp/gmh3XZfq" "-c" "quit" (child process quit due to signal 11).
gm convert: Request did not return an image.

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

Successfully merging this pull request may close these issues.

1 participant