cin.clear() fix for output filename prompt
error if statement fix on bad read
probably broke more than fixed
Broke much more than fixed