fix indent
this code is possibly not required
fixed segmentation fault
do not exit on invalid format