#14 bug fix

#14 bug fix, tested on Nexus One(with android 2.3.3) and Nexus 4(with android 4.4.4)