Catch out of memory errors in a few places.

git-svn-id: https://android.svn.wordpress.org/trunk@922 a6565c4b-a94d-4d28-bb26-aa9e5ab542c0