Re-land : Fixed WebGL printing crash due to failed buffer allocation

Change since previous revert: reduced canvas size in layout
test to prevent OOM from crbug.com/538697

BUG=537711
R=kbr@chromium.org

Review URL: https://codereview.chromium.org/1380633003

Cr-Commit-Position: refs/heads/master@{#352170}
3 files changed