From koffice Tue May 11 14:47:37 2004 From: David Faure Date: Tue, 11 May 2004 14:47:37 +0000 To: koffice Subject: [Bug 54459] Security: backup files get different permissions Message-Id: <20040511144737.17898.qmail () ktown ! kde ! org> X-MARC-Message: https://marc.info/?l=koffice&m=108428688016427 ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. http://bugs.kde.org/show_bug.cgi?id=54459 faure kde org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |FIXED ------- Additional Comments From faure kde org 2004-05-11 16:47 ------- CVS commit by faure: Oh well, I suck. Now this should fix 54459 again. I'll backport. CCMAIL: 54459-done bugs kde org M +4 -4 koDocument.cc 1.308 --- koffice/lib/kofficecore/koDocument.cc #1.307:1.308 @ -48,7 +48,7 @ #include #include +#include #if ! KDE_IS_VERSION(3,1,90) #include -#include #endif @ -383,9 +383,9 @ bool KoDocument::saveFile() backup = d->m_backupPath +"/"+url().fileName(); backup.setPath( backup.path() + QString::fromLatin1("~") ); -#if KDE_IS_VERSION(3,1,90) - KIO::NetAccess::file_copy( url(), backup, -1, true /*overwrite*/, false /*resume*/, shells().current() ); -#else KFileItem item( entry, url() ); Q_ASSERT( item.name() == url().fileName() ); +#if KDE_IS_VERSION(3,1,90) + KIO::NetAccess::file_copy( url(), backup, item.permissions(), true /*overwrite*/, false /*resume*/, shells().current() ); +#else KIO::NetAccess::del( backup ); // Copy does not remove existing destination file KIO::NetAccess::copy( url(), backup ); ____________________________________ koffice mailing list koffice@mail.kde.org To unsubscribe please visit: https://mail.kde.org/mailman/listinfo/koffice