diff options
author | Hennes Rohling <hro@openoffice.org> | 2001-03-16 10:21:05 +0000 |
---|---|---|
committer | Hennes Rohling <hro@openoffice.org> | 2001-03-16 10:21:05 +0000 |
commit | d8eb8f1631045c5a5fdfb34b21ce8d01c455cf24 (patch) | |
tree | 71769bf1baa2194e98f07ede97fff605eed5c851 /ucb/source/ucp | |
parent | c249dc4f4c8f00cdd642463f1060f2c3fe8a006c (diff) |
#84996# copy_recursive should terminate with an error if an error ocured during a sub call
Diffstat (limited to 'ucb/source/ucp')
-rw-r--r-- | ucb/source/ucp/file/shell.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/ucb/source/ucp/file/shell.cxx b/ucb/source/ucp/file/shell.cxx index ca5c2300bd1e..1ca13e3d6df7 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.26 $ + * $Revision: 1.27 $ * - * last change: $Author: sb $ $Date: 2001-03-08 15:05:21 $ + * last change: $Author: hro $ $Date: 2001-03-16 11:21:05 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -2372,7 +2372,7 @@ shell::copy_recursive( const rtl::OUString& srcUnqPath, osl::DirectoryItem aDirItem; - while( ( next = aDir.getNextItem( aDirItem ) ) == osl::FileBase::E_None ) + while( err == osl::FileBase::E_None && ( next = aDir.getNextItem( aDirItem ) ) == osl::FileBase::E_None ) { sal_Bool IsDocument; osl::FileStatus aFileStatus( n_Mask ); @@ -2396,11 +2396,11 @@ shell::copy_recursive( const rtl::OUString& srcUnqPath, newDstUnqPath += tit; if ( newSrcUnqPath != dstUnqPath ) - copy_recursive( newSrcUnqPath,newDstUnqPath,newTypeToCopy,false ); + err = copy_recursive( newSrcUnqPath,newDstUnqPath,newTypeToCopy,false ); } - if( next != osl::FileBase::E_NOENT ) - err = osl::FileBase::E_INVAL; + if( err == osl::FileBase::E_None && next != osl::FileBase::E_NOENT ) + err = next; } aDir.close(); } |