[connman] Rework setting interface pointer to null

Check wifi struct pointer before setting a field in it.