Skip to content
Commit 6ce5d2f8 authored by rk flx's avatar rk flx Committed by Luigi Toscano
Browse files

Avoid data loss when importing pictures

Summary:
Fix porting regressions, which left users of Gwenview Importer with:
- failed import (import destination still empty)
- additionally (when choosing "Delete" instead of "Keep" after import):
  pictures also removed from import source, with no way to recover

Correct additional problems remaining after fixing the import failure:
- hang on duplicate filenames
- identically named files with different content are never imported
- error dialog when deleting pictures from import source

BUG: 379615

In detail:

1st problem (introduced in 017b4fe5):

  Initially, pictures are copied to a temporary folder
  (e.g. "foo/.gwenview_importer-IcQqvo/"), before being moved/renamed
  to the final destination (e.g. "foo/"), which is determined by
  calling "cd .." on the temporary folder.

  However, mistakenly this path contains a superfluous '/'
  (e.g. "foo/.gwenview_importer-IcQqvo//"), resulting in the final
  destination reading "foo/.gw...
parent 05e03cfd
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment