Fix problem with space added to password coming from a file name.

Regression caused by redesign of password scanner.