Fix pscheck.main for direct command line use