Small changes, fixed getopt