Fix parsing of common options