fix some errors, force closes

Change-Id: Ide59a1d1734fc47bb803a6c25c430fcbf31f0bc1