summaryrefslogtreecommitdiffstats
path: root/tdeioslave
diff options
context:
space:
mode:
Diffstat (limited to 'tdeioslave')
-rw-r--r--tdeioslave/file/file.cpp2
-rw-r--r--tdeioslave/ftp/ftp.cpp2
-rw-r--r--tdeioslave/http/http.cpp2
-rw-r--r--tdeioslave/http/http_cache_cleaner.cpp2
-rw-r--r--tdeioslave/iso/iso.cpp4
-rw-r--r--tdeioslave/iso/kiso.cpp28
-rw-r--r--tdeioslave/iso/qfilehack.h2
7 files changed, 26 insertions, 16 deletions
diff --git a/tdeioslave/file/file.cpp b/tdeioslave/file/file.cpp
index ba13cc10f..ba42792ee 100644
--- a/tdeioslave/file/file.cpp
+++ b/tdeioslave/file/file.cpp
@@ -73,7 +73,7 @@
#include <kshred.h>
#include <kdebug.h>
#include <kurl.h>
-#include <kinstance.h>
+#include <tdeinstance.h>
#include <tdesimpleconfig.h>
#include <tdetempfile.h>
#include <tdelocale.h>
diff --git a/tdeioslave/ftp/ftp.cpp b/tdeioslave/ftp/ftp.cpp
index 8a87305f6..780e999cb 100644
--- a/tdeioslave/ftp/ftp.cpp
+++ b/tdeioslave/ftp/ftp.cpp
@@ -53,7 +53,7 @@
#include <kdebug.h>
#include <tdelocale.h>
-#include <kinstance.h>
+#include <tdeinstance.h>
#include <kmimemagic.h>
#include <kmimetype.h>
#include <ksockaddr.h>
diff --git a/tdeioslave/http/http.cpp b/tdeioslave/http/http.cpp
index 5cc638bd0..7520349d9 100644
--- a/tdeioslave/http/http.cpp
+++ b/tdeioslave/http/http.cpp
@@ -57,7 +57,7 @@
#include <kservice.h>
#include <krfcdate.h>
#include <kmdcodec.h>
-#include <kinstance.h>
+#include <tdeinstance.h>
#include <kresolver.h>
#include <kmimemagic.h>
#include <dcopclient.h>
diff --git a/tdeioslave/http/http_cache_cleaner.cpp b/tdeioslave/http/http_cache_cleaner.cpp
index 08ca740b2..0375042e8 100644
--- a/tdeioslave/http/http_cache_cleaner.cpp
+++ b/tdeioslave/http/http_cache_cleaner.cpp
@@ -32,7 +32,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#include <tqstring.h>
#include <tqptrlist.h>
-#include <kinstance.h>
+#include <tdeinstance.h>
#include <tdelocale.h>
#include <tdecmdlineargs.h>
#include <tdeglobal.h>
diff --git a/tdeioslave/iso/iso.cpp b/tdeioslave/iso/iso.cpp
index 4688a3e7a..40a7eb738 100644
--- a/tdeioslave/iso/iso.cpp
+++ b/tdeioslave/iso/iso.cpp
@@ -30,7 +30,7 @@
#include <tqfile.h>
#include <kurl.h>
#include <kdebug.h>
-#include <kinstance.h>
+#include <tdeinstance.h>
#include <kiso.h>
#include <kmimemagic.h>
@@ -274,7 +274,7 @@ void tdeio_isoProtocol::listDir( const KURL & url )
const KArchiveDirectory* dir;
if (!path.isEmpty() && path != "/")
{
- kdDebug() << TQString(TQString("Looking for entry %1").arg(path)) << endl;
+ kdDebug() << TQString("Looking for entry %1").arg(path) << endl;
const KArchiveEntry* e = root->entry( path );
if ( !e )
{
diff --git a/tdeioslave/iso/kiso.cpp b/tdeioslave/iso/kiso.cpp
index fdd2df413..bcc11810d 100644
--- a/tdeioslave/iso/kiso.cpp
+++ b/tdeioslave/iso/kiso.cpp
@@ -16,7 +16,7 @@
***************************************************************************/
/* This file is heavily based on ktar.cpp from tdelibs (c) David Faure */
-
+
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
@@ -125,6 +125,8 @@ KIso::KIso( const TQString& filename, const TQString & _mimetype )
mimetype = "application/x-gzip";
else if ( mimetype == "application/x-tbz" ) // that's a bzipped2 tar file, so ask for bz2 filter
mimetype = "application/x-bzip2";
+ else if ( mimetype == "application/x-txz" ) // that's a xzipped tar file, so ask for xz filter
+ mimetype = "application/x-xz";
else
{
// Something else. Check if it's not really gzip though (e.g. for KOffice docs)
@@ -144,6 +146,14 @@ KIso::KIso( const TQString& filename, const TQString & _mimetype )
if ( fourthByte == 4 )
mimetype = "application/x-zip";
}
+ else if ( firstByte == 0xfd && secondByte == '7' && thirdByte == 'z' )
+ {
+ unsigned char fourthByte = file.getch();
+ unsigned char fifthByte = file.getch();
+ unsigned char sixthByte = file.getch();
+ if ( fourthByte == 'X' && fifthByte == 'Z' && sixthByte == 0)
+ mimetype = "application/x-xz";
+ }
}
}
forced = false;
@@ -155,13 +165,13 @@ KIso::KIso( const TQString& filename, const TQString & _mimetype )
void KIso::prepareDevice( const TQString & filename,
const TQString & mimetype, bool forced )
{
- /* 'hack' for Qt's false assumption that only S_ISREG is seekable */
+ /* 'hack' for TQt's false assumption that only S_ISREG is seekable */
if( "inode/blockdevice" == mimetype )
setDevice( new QFileHack( filename ) );
else
{
- if( "application/x-gzip" == mimetype
- || "application/x-bzip2" == mimetype)
+ if("application/x-gzip" == mimetype || "application/x-bzip2" == mimetype ||
+ "application/x-xz" == mimetype)
forced = true;
TQIODevice *dev = KFilterDev::deviceForFile( filename, mimetype, forced );
@@ -295,7 +305,7 @@ void KIso::addBoot(struct el_torito_boot_descriptor* bootdesc) {
boot_entry *be;
TQString path;
KIsoFile *entry;
-
+
entry=new KIsoFile( this, "Catalog", dirent->permissions() & ~S_IFDIR,
dirent->date(), dirent->adate(), dirent->cdate(),
dirent->user(), dirent->group(), TQString::null,
@@ -327,7 +337,7 @@ void KIso::readParams()
TDEConfig *config;
config = new TDEConfig("tdeio_isorc");
-
+
showhidden=config->readBoolEntry("showhidden",false);
showrr=config->readBoolEntry("showrr",true);
delete config;
@@ -373,7 +383,7 @@ bool KIso::openArchive( int mode )
if (trackno==0) trackno=1;
for (i=0;i<trackno;i++) {
- c_b=1;c_i=1;c_j=1;
+ c_b=1;c_i=1;c_j=1;
root=rootDir();
if (trackno>1) {
path=TQString::null;
@@ -397,11 +407,11 @@ bool KIso::openArchive( int mode )
if ( !memcmp(EL_TORITO_ID,bootdesc->system_id,ISODCL(8,39)) ) {
path="El Torito Boot";
if (c_b>1) path += " (" + TQString::number(c_b) + ")";
-
+
dirent = new KIsoDirectory( this, path, access | S_IFDIR,
buf.st_mtime, buf.st_atime, buf.st_ctime, uid, gid, TQString::null );
root->addEntry(dirent);
-
+
addBoot(bootdesc);
c_b++;
}
diff --git a/tdeioslave/iso/qfilehack.h b/tdeioslave/iso/qfilehack.h
index 3f0b1f6a6..fe43217b2 100644
--- a/tdeioslave/iso/qfilehack.h
+++ b/tdeioslave/iso/qfilehack.h
@@ -23,7 +23,7 @@
/**
*@author Szombathelyi György
- * Qt thinks if a file is not S_IFREG, you cannot seek in it. It's false (what about
+ * TQt thinks if a file is not S_IFREG, you cannot seek in it. It's false (what about
* block devices for example?
*/