fix segfault when -c is indicated without an argument