Fixed null pointer exception in circuit switching