in newId(), url *u = fifo[outFifo] could be NULL. It should be judged before access its host and port.