fix some bug for use multi-thread in on android.