diff options
author | makc <makc@FreeBSD.org> | 2010-09-20 04:41:53 +0800 |
---|---|---|
committer | makc <makc@FreeBSD.org> | 2010-09-20 04:41:53 +0800 |
commit | 3af3735e7ac4283d23290657a123a190d6881f69 (patch) | |
tree | a728b41de7fc5d7021d5a31b663b869f81ce7569 | |
parent | 291c5a9d46e281c77c92bd5383a8d78a4c3b2855 (diff) | |
download | freebsd-ports-gnome-3af3735e7ac4283d23290657a123a190d6881f69.tar.gz freebsd-ports-gnome-3af3735e7ac4283d23290657a123a190d6881f69.tar.zst freebsd-ports-gnome-3af3735e7ac4283d23290657a123a190d6881f69.zip |
Add patch from upstream to fix regression for ZIP files
-rw-r--r-- | x11/kdelibs4/Makefile | 1 | ||||
-rw-r--r-- | x11/kdelibs4/files/patch-1171342 | 39 |
2 files changed, 40 insertions, 0 deletions
diff --git a/x11/kdelibs4/Makefile b/x11/kdelibs4/Makefile index 7b44738ad54b..31e1523261aa 100644 --- a/x11/kdelibs4/Makefile +++ b/x11/kdelibs4/Makefile @@ -8,6 +8,7 @@ PORTNAME= kdelibs PORTVERSION= ${KDE4_VERSION} +PORTREVISION= 1 CATEGORIES= x11 kde ipv6 MASTER_SITES= ${MASTER_SITE_KDE} MASTER_SITE_SUBDIR= ${KDE4_BRANCH}/${PORTVERSION}/src diff --git a/x11/kdelibs4/files/patch-1171342 b/x11/kdelibs4/files/patch-1171342 new file mode 100644 index 000000000000..e2b9fa34b38e --- /dev/null +++ b/x11/kdelibs4/files/patch-1171342 @@ -0,0 +1,39 @@ +--- ./kdecore/io/karchive.cpp 2010/08/24 19:50:56 1167508 ++++ ./kdecore/io/karchive.cpp 2010/09/03 13:29:40 1171342 +@@ -634,7 +634,10 @@ + + QByteArray KArchiveFile::data() const + { +- archive()->device()->seek( d->pos ); ++ bool ok = archive()->device()->seek( d->pos ); ++ if (!ok) { ++ kWarning() << "Failed to sync to" << d->pos << "to read" << name(); ++ } + + // Read content + QByteArray arr; +@@ -661,7 +664,7 @@ + QFile f( dest + '/' + name() ); + if ( f.open( QIODevice::ReadWrite | QIODevice::Truncate ) ) + { +- archive()->device()->seek( d->pos ); ++ QIODevice* inputDev = createDevice(); + + // Read and write data in chunks to minimize memory usage + const qint64 chunkSize = 1024 * 1024; +@@ -671,12 +674,14 @@ + + while ( remainingSize > 0 ) { + const qint64 currentChunkSize = qMin( chunkSize, remainingSize ); +- const qint64 n = archive()->device()->read( array.data(), currentChunkSize ); ++ const qint64 n = inputDev->read( array.data(), currentChunkSize ); + Q_ASSERT( n == currentChunkSize ); + f.write( array.data(), currentChunkSize ); + remainingSize -= currentChunkSize; + } + f.close(); ++ ++ delete inputDev; + } + } + |