<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.kde.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugs.kde.org/"
          
          maintainer="sysadmin@kde.org"
>

    <bug>
          <bug_id>318757</bug_id>
          
          <creation_ts>2013-04-23 10:47:18 +0000</creation_ts>
          <short_desc>Cancelling file overwrite dialog modifies clipboard contents</short_desc>
          <delta_ts>2013-08-05 11:53:42 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>10</classification_id>
          <classification>Unmaintained</classification>
          <product>kio</product>
          <component>general</component>
          <version>4.10.2</version>
          <rep_platform>Compiled Sources</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>NOR</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Christoph Feck">cfeck</reporter>
          <assigned_to name="David Faure">faure</assigned_to>
          <cc>frank78ac</cc>
          
          <cf_commitlink>http://commits.kde.org/kdelibs/e4b786f6df87aba226931082e5ad2791ac529978</cf_commitlink>
          <cf_versionfixedin>4.11</cf_versionfixedin>
          <cf_sentryurl></cf_sentryurl>
          <votes>0</votes>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1363310</commentid>
    <comment_count>0</comment_count>
    <who name="Christoph Feck">cfeck</who>
    <bug_when>2013-04-23 10:47:18 +0000</bug_when>
    <thetext>To reproduce:
- make two folders A and B both containing a &quot;file.txt&quot; file
- in folder A, mark &quot;file.txt&quot; and select &quot;Cut&quot; from context menu
- go to folder B, and select &quot;Paste&quot; from context menu
- the file overwrite dialog appears, cancel it
- select &quot;Paste&quot; again

Expected results:
- the file overwrite dialog appears again

Actual results:
- a different message appears indicating a different file would be moved
- the original path &quot;A/file.txt&quot; is no longer in clipboard, but &quot;B/file.txt&quot; is

Tested with today&apos;s git/master.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1363321</commentid>
    <comment_count>1</comment_count>
    <who name="Frank Reininghaus">frank78ac</who>
    <bug_when>2013-04-23 11:02:22 +0000</bug_when>
    <thetext>Thanks for the report. I believe that the bug is in

static KIO::Job *pasteClipboardUrls(const QMimeData* mimeData, const KUrl&amp; destDir, KIO::JobFlags flags = KIO::DefaultFlags)

in kdelibs/kio/kio/paste.cpp. It updates the clipboard just after starting the job, when it&apos;s not known yet if pasting succeeds or not.

http://code.woboq.org/kde/kdelibs/kio/kio/paste.cpp.html#_ZL18pasteClipboardUrlsPK9QMimeDataRK4KUrl6QFlagsIN3KIO7JobFlagEE</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1385080</commentid>
    <comment_count>2</comment_count>
    <who name="Dawit Alemayehu">adawit</who>
    <bug_when>2013-07-21 18:31:58 +0000</bug_when>
    <thetext>Git commit e4b786f6df87aba226931082e5ad2791ac529978 by Dawit Alemayehu.
Committed on 18/07/2013 at 06:11.
Pushed by adawit into branch &apos;KDE/4.11&apos;.

Don&apos;t update clipboard before cut/paste operation succeedes.
FIXED-IN: 4.11
REVIEW: 111585

M  +1    -0    kio/CMakeLists.txt
A  +107  -0    kio/kio/clipboardupdater.cpp     [License: LGPL (v2+)]
A  +64   -0    kio/kio/clipboardupdater_p.h     [License: LGPL (v2+)]
M  +2    -0    kio/kio/fileundomanager.cpp
M  +2    -12   kio/kio/paste.cpp
M  +38   -1    kio/tests/fileundomanagertest.cpp
M  +1    -0    kio/tests/fileundomanagertest.h

http://commits.kde.org/kdelibs/e4b786f6df87aba226931082e5ad2791ac529978</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1387621</commentid>
    <comment_count>3</comment_count>
    <who name="Dawit Alemayehu">adawit</who>
    <bug_when>2013-08-02 12:37:23 +0000</bug_when>
    <thetext>Git commit 2f19231bc9f32f2642df9556af81ce339307b091 by Dawit Alemayehu.
Committed on 29/07/2013 at 02:28.
Pushed by adawit into branch &apos;KDE/4.11&apos;.

Update URLs copied to clipboard if they change as a result of KIO operations.
Related: bug 134960
FIXED-IN: 4.11
REVIEW: 111776

M  +84   -12   kio/kio/clipboardupdater.cpp
M  +15   -3    kio/kio/clipboardupdater_p.h
M  +10   -3    kio/kio/copyjob.cpp
M  +7    -2    kio/kio/deletejob.cpp
M  +8    -2    kio/kio/job.cpp
M  +5    -6    kio/kio/paste.cpp
M  +1    -0    kio/tests/CMakeLists.txt
A  +168  -0    kio/tests/clipboardupdatertest.cpp     [License: LGPL (v2+)]
A  +37   -0    kio/tests/clipboardupdatertest.h     [License: LGPL (v2+)]
M  +8    -8    kio/tests/fileundomanagertest.cpp
M  +1    -1    kio/tests/fileundomanagertest.h

http://commits.kde.org/kdelibs/2f19231bc9f32f2642df9556af81ce339307b091</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1387640</commentid>
    <comment_count>4</comment_count>
    <who name="Dawit Alemayehu">adawit</who>
    <bug_when>2013-08-02 13:57:36 +0000</bug_when>
    <thetext>Git commit 2f5218463d1b7b7fc6eb17feee1195deacda1577 by Dawit Alemayehu.
Committed on 02/08/2013 at 13:47.
Pushed by adawit into branch &apos;KDE/4.11&apos;.

Updates last commit with minor and cosmetic changes.

REVIEW: 111776
Related: bug 134960

M  +10   -12   kio/kio/clipboardupdater.cpp
M  +4    -0    kio/kio/clipboardupdater_p.h
M  +3    -3    kio/tests/clipboardupdatertest.cpp

http://commits.kde.org/kdelibs/2f5218463d1b7b7fc6eb17feee1195deacda1577</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1388036</commentid>
    <comment_count>5</comment_count>
    <who name="Dawit Alemayehu">adawit</who>
    <bug_when>2013-08-05 11:53:42 +0000</bug_when>
    <thetext>Git commit 9b0b5ec1a6396b051f65bf23cdf9d9949aa9c3ec by Dawit Alemayehu.
Committed on 05/08/2013 at 06:23.
Pushed by adawit into branch &apos;KDE/4.11&apos;.

Fix unintended runtime dependency introduced when fixing #134960.

REVIEW: 111776
Related: bug 134960

M  +26   -7    kio/kio/clipboardupdater.cpp
M  +7    -1    kio/kio/clipboardupdater_p.h
M  +3    -3    kio/kio/copyjob.cpp
M  +2    -2    kio/kio/deletejob.cpp
M  +1    -1    kio/kio/fileundomanager.cpp
M  +2    -2    kio/kio/job.cpp
M  +3    -2    kio/kio/paste.cpp

http://commits.kde.org/kdelibs/9b0b5ec1a6396b051f65bf23cdf9d9949aa9c3ec</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>