Quote:
Originally Posted by
zixzix01
Thanks for your input Chubler, I did put in those corrections
You might want to undo the extra >$TMP, it's pointless. see above.
Keep the extra quotes though.
---------- Post updated at 03:16 PM ---------- Previous update was at 03:14 PM ----------
Quote:
Originally Posted by
zixzix01
Sorry Corona, defensive quoting?
The difference between
$fname and
"$fname" is that the former will split into several arguments if $fname happens to have a space in it, while "$fname" will remain as one argument with a space in it. Splitting would be bad, as it might try to handle "/path/dir with space/file" as three files, "/path/dir", "with", and "space/file", and complain that it can't find any of them.
He's put it in quotes like "$fname", then added another layer of quotes like "\"$fname\"" to make sure it gets quoted on the remote machine too -- one layer of quotes gets stripped off of whatever you feed into ssh.