Fix bug in "create network" command.

If you press Cancel in the network name popup, NodeBox crashes.

This fixes #316.