trafgen: fix NULL pointer dereference in -i option parsing