gallery/gallery3 — pull request #108 by shadlaws (2013-01-28 13:19:39+00:00)
Title: #1970 - Make add watermarks more secure and add unit tests.

This follows #1855 and #1951...
- Ensured that invalid or illegal files are not added even if they have valid extensions.
- Added unit tests (currently there aren't any...)