fix service loop not stop when logout

Add android and iOS platform