handle some resources leak like broadcast receiver and wifi networkid