Check if mText is null before invoke toString()

Change-Id: I8b519fa42e928eb157248e6b896a8958f281f9cd
Signed-off-by: Roger Chen <cxr514033970@gmail.com>
Prevent FC in low memory conditions

Add missing null cursor checks

Signed-off-by: Michael Bestas <mikeioannina@gmail.com>

Change-Id: I974eea82cac3dfe3a01e5d79c1721d3514f940f6