Improve untar when using files instead of directories. Specifies behavior on non-existant targets.

Related to #6580

Docker-DCO-1.1-Signed-off-by: Tibor Vass <teabee89@gmail.com> (github: tiborvass)