Fixed a stupid bug with the return value type of getopt.