summaryrefslogtreecommitdiff
path: root/ucb/source
diff options
context:
space:
mode:
authorAndreas Bille <abi@openoffice.org>2001-02-19 09:17:05 +0000
committerAndreas Bille <abi@openoffice.org>2001-02-19 09:17:05 +0000
commitbb7ce7e613dc68feca4850b0d1f04bd908a1c061 (patch)
tree6079564b4c0c5b5bc2fa888d875bf639d784510b /ucb/source
parent9b314d293b4eab644065e7728608aacc2b0110e7 (diff)
#83141#
Checking whether goal and source of copy and move are the same.
Diffstat (limited to 'ucb/source')
-rw-r--r--ucb/source/ucp/file/shell.cxx10
1 files changed, 8 insertions, 2 deletions
diff --git a/ucb/source/ucp/file/shell.cxx b/ucb/source/ucp/file/shell.cxx
index 69d2e238f01c..6b51b035d824 100644
--- a/ucb/source/ucp/file/shell.cxx
+++ b/ucb/source/ucp/file/shell.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: shell.cxx,v $
*
- * $Revision: 1.19 $
+ * $Revision: 1.20 $
*
- * last change: $Author: sb $ $Date: 2001-02-12 13:50:07 $
+ * last change: $Author: abi $ $Date: 2001-02-19 10:17:05 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -2199,6 +2199,9 @@ shell::move( sal_Int32 CommandId,
{
rtl::OUString dstUnqPath( dstUnqPathIn );
+ if( dstUnqPath == srcUnqPath ) // Nothing left to be done
+ return;
+
// Moving file or folder ?
osl::DirectoryItem aItem;
osl::FileBase::RC err = osl::DirectoryItem::get( srcUnqPath,aItem );
@@ -2383,6 +2386,9 @@ shell::copy(
{
rtl::OUString dstUnqPath( dstUnqPathIn );
+ if( dstUnqPath == srcUnqPath ) // Nothing left to be done
+ return;
+
// Moving file or folder ?
osl::DirectoryItem aItem;
osl::FileBase::RC err = osl::DirectoryItem::get( srcUnqPath,aItem );