diff options
author | François Andriot <albator78@libertysurf.fr> | 2013-06-24 19:58:32 +0200 |
---|---|---|
committer | François Andriot <albator78@libertysurf.fr> | 2013-06-24 19:58:32 +0200 |
commit | d8e1ce857bedb9d018ae0918b4c90686d604c2df (patch) | |
tree | 111a8759c0599ce2be8d25946d21dee4f69923b9 /redhat/tdelibs/tdelibs-3.5.13.2-fix_kzip_empty_directory.patch | |
parent | 8743b3f65cd27e30aefe49f127105aa305a86051 (diff) | |
download | tde-packaging-d8e1ce857bedb9d018ae0918b4c90686d604c2df.tar.gz tde-packaging-d8e1ce857bedb9d018ae0918b4c90686d604c2df.zip |
RPM Packaging: add 3.5.13.2 build patches
Diffstat (limited to 'redhat/tdelibs/tdelibs-3.5.13.2-fix_kzip_empty_directory.patch')
-rw-r--r-- | redhat/tdelibs/tdelibs-3.5.13.2-fix_kzip_empty_directory.patch | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/redhat/tdelibs/tdelibs-3.5.13.2-fix_kzip_empty_directory.patch b/redhat/tdelibs/tdelibs-3.5.13.2-fix_kzip_empty_directory.patch new file mode 100644 index 000000000..e56d7559d --- /dev/null +++ b/redhat/tdelibs/tdelibs-3.5.13.2-fix_kzip_empty_directory.patch @@ -0,0 +1,38 @@ +--- ./kio/kio/kzip.cpp.ORI 2013-05-31 23:15:23.021298550 +0200 ++++ ./kio/kio/kzip.cpp 2013-05-31 23:16:43.525633640 +0200 +@@ -1051,6 +1051,21 @@ + return true; + } + ++bool KZip::writeDir(const TQString& name, const TQString& user, const TQString& group) ++{ ++ // Zip files have no explicit directories, they are implicitly created during extraction time ++ // when file entries have paths in them. ++ // However, to support empty directories, we must create a dummy file entry which ends with '/'. ++ TQString dirName = name; ++ if (!name.endsWith("/")) { ++ dirName = dirName.append('/'); ++ } ++ ++ mode_t perm = 040755; ++ time_t the_time = time(0); ++ return writeFile(dirName, user, group, 0, perm, the_time, the_time, the_time, 0); ++} ++ + // Doesn't need to be reimplemented anymore. Remove for KDE-4.0 + bool KZip::writeFile( const TQString& name, const TQString& user, const TQString& group, uint size, const char* data ) + { +--- ./kio/kio/kzip.h.ORI 2013-05-31 23:18:30.829414791 +0200 ++++ ./kio/kio/kzip.h 2013-05-31 23:19:10.763589109 +0200 +@@ -191,10 +191,7 @@ + /// Closes the archive + virtual bool closeArchive(); + +- /** +- * @internal Not needed for zip +- */ +- virtual bool writeDir( const TQString& name, const TQString& user, const TQString& group) { Q_UNUSED(name); Q_UNUSED(user); Q_UNUSED(group); return true; } ++ virtual bool writeDir(const QString& name, const QString& user, const QString& group); + // TODO(BIC) uncomment and make virtual for KDE 4. + // bool writeDir( const TQString& name, const TQString& user, const TQString& group, + // mode_t perm, time_t atime, time_t mtime, time_t ctime ); |