Fix filter parameter in toBuffer method #356

Merged
merged 1 commit into from Dec 6, 2013

Conversation

Projects
None yet
3 participants
Contributor

selaux commented Nov 14, 2013

I tried to write a png to disk using a custom compressionLevel and filter method. But it always failed with libpng error: Unknown row filter for method 0. I found this line in the code and it seems to me that the filter is using the wrong index for the parameter (args[1] is compressionLevel). So I fixed it.

selaux referenced this pull request in selaux/node-sprite-generator Nov 14, 2013

Closed

Allow user to specify png filter option #10

Contributor

selaux commented Nov 20, 2013

Any thoughts?

Contributor

kkoopa commented Nov 26, 2013

Yes, you are definitely correct, the rows around check for the correct index, I must have been sloppy writing that, looks like bad copypasta.

selaux referenced this pull request in selaux/node-sprite-generator Dec 5, 2013

Closed

Change compression to 0-100, update docs. #12

@kangax kangax added a commit that referenced this pull request Dec 6, 2013

@kangax kangax Merge pull request #356 from selaux/fix-filter-parameter
Fix filter parameter in toBuffer method
5cc0a5f

@kangax kangax merged commit 5cc0a5f into Automattic:master Dec 6, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment