Skip to content
This repository has been archived by the owner on Jul 10, 2023. It is now read-only.

Add to_vec function for writing PNG data to a Vec<u8>. #68

Merged
merged 2 commits into from
Apr 29, 2015

Conversation

jgraham
Copy link
Contributor

@jgraham jgraham commented Apr 28, 2015

This mostly copies the implementation of store_png, and could
probably be refactored to share more code in the future.

@metajack
Copy link
Contributor

Can you add a test for this? I figured it would call to_vec and then verify the first bytes were the PNG magic bytes and that the total length was the expected one.

Otherwise, looks fine.

This mostly copies the implementation of store_png, and could
probably be refactored to share more code in the future.
@jgraham
Copy link
Contributor Author

jgraham commented Apr 28, 2015

This is rebased onto master, but with the tests in a separate commit, because they won't trivially backport to the current servo branch (but the actual functionality will).

@metajack
Copy link
Contributor

Squash and r=me.

@metajack
Copy link
Contributor

Or are you saying you want to leave the tests in their own commit? If so, maybe change the commit message to not have fixup! in it?

@jgraham
Copy link
Contributor Author

jgraham commented Apr 29, 2015

I'm happy to squash, but unless the rust upgrade is about to land it would be useful to create a servo branch with 16a9dba cherry-picked on top of the current servo commit.

@metajack
Copy link
Contributor

Seems reasonable then. Just change the commit message to 'Add tests for to_vec.' and I'll merge this.

metajack added a commit that referenced this pull request Apr 29, 2015
Add to_vec function for writing PNG data to a Vec<u8>.
@metajack metajack merged commit 06ec44b into servo:master Apr 29, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants