Merge pull request #3324 from mdboom/backend-agg-crash

BUG : fixes memory corruption issues with zero-size rasterized artists

Fix #3304.