Media process is crashing with NullPointer exception

Sometime, while creating thumnails list of media files in
compose MMS->attach file,  filepath may be null due to
synchronization issue.
Adding NULL check to avoid NUllPointer exception.

Change-Id: Id6cf5612a959b3ae15b44bc60dbbcbe40c624f09
CRs-Fixed: 636494
wallpapercropper: OOM issue while opening *.bmp image

This change manages setting of large images as
wallpapers without encountering OOM.

CRs-fixed: 619815
Change-Id: I3a32ec4b42050b146076f0adf6b6e65afd6fae4e

Conflicts:
	packages/WallpaperCropper/src/com/android/wallpapercropper/WallpaperCropActivity.java