Fixed a couple of bugs with argument processing.