Ivailo Monev
591e73ca63
kutils: update readable and writable KArchive MIME types
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-15 19:47:08 +03:00
Ivailo Monev
04fa9c4bf9
Merge branch 'master' of https://scm.osdn.net/gitroot/kde/kdelibs
2022-10-15 19:38:39 +03:00
Ivailo Monev
37c782601f
kutils: mark KArchive and KSpeech as stable
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-15 19:45:37 +03:00
Ivailo Monev
3f28263411
kutils: when opening archive fails in helper methods return null
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-15 19:36:59 +03:00
Ivailo Monev
1dfb02b361
kutils: slightly better writable archive check
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-11 07:38:27 +03:00
Ivailo Monev
8d2453c1be
kutils: manually set the archive filter when it is known to not be recognized by libarchive
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-11 07:31:53 +03:00
Ivailo Monev
c37e70c894
kutils: set the group and username of new archive entries
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-10 01:49:25 +03:00
Ivailo Monev
2c7288649c
kutils: stub KArchive progress signal
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-09 21:02:31 +03:00
Ivailo Monev
b3a991b9d6
kutils: test listing and extraction of password-protected archive
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-09 18:04:16 +03:00
Ivailo Monev
8caebd2d4f
Revert "kutils: fix archive entry double-free in case of archive_write_header() failure"
...
This reverts commit faefab7258
.
2022-10-09 16:00:17 +03:00
Ivailo Monev
e82f83a22a
kutils: implement methods for checking if archive requires passphrase and set one for reading and writing
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-09 15:36:08 +03:00
Ivailo Monev
faefab7258
kutils: fix archive entry double-free in case of archive_write_header() failure
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-09 15:26:27 +03:00
Ivailo Monev
578396197e
kutils: correct archive_read_extract2() failure error reporting
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-09 15:03:06 +03:00
Ivailo Monev
8009f7d734
kutils: remove extra dot in tmpName() function
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-09 06:02:01 +03:00
Ivailo Monev
02229df53a
kutils: read the next header before skipping if path does not match in KArchive::list()
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-09 05:38:52 +03:00
Ivailo Monev
4ff227e336
kdecore: emulate cross-filesystem move in KDE::rename()
...
if the temporary directory is of tmpfs type (which is the case on
Debian) then moving temporary files will fail thus thumbnails will not be
cached for example because they are stored as temporary file first and
then moved to ~/.thumbnails
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-07 22:38:57 +03:00
Ivailo Monev
0e3275dc35
kutils: make use of the new KTemporaryFile::filePath() method
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-07 05:22:41 +03:00
Ivailo Monev
9afece26a8
kutils: implement operator equal for KArchiveEntry
...
required to check if QList<KArchiveEntry> contains KArchiveEntry for example
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-06 21:31:25 +03:00
Ivailo Monev
720e62b6f1
kutils: check if the leading directory is writable from KArchive constructor
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-06 19:58:29 +03:00
Ivailo Monev
95162630d4
kutils: process events while iterating over the paths that need to be added in KArchive::add()
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-06 22:28:16 +03:00
Ivailo Monev
6d66041086
kutils: zero-initialize the readlink() buffer in KArchive::add()
...
fixes adding to archive in case of symlink
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-06 22:22:52 +03:00
Ivailo Monev
16ebe8408f
kutils: copy-pasta typo
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-06 22:21:40 +03:00
Ivailo Monev
779bb0e9ab
kutils: KArchive documentation update
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-06 21:33:45 +03:00
Ivailo Monev
14f75001ba
kutils: set the passphase callback to dummy one for now
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-06 21:09:54 +03:00
Ivailo Monev
2a0f817096
kutils: build fix for the case when strmode() is available
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-06 21:07:26 +03:00
Ivailo Monev
587259b61f
kutils: save errno value before calling functions that may change it in KArchive::add()
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-06 20:31:54 +03:00
Ivailo Monev
2170542166
kutils: define PATH_MAX to _POSIX_PATH_MAX if it is not defined
...
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-06 20:30:50 +03:00
Ivailo Monev
3ab3f3b47f
kutils: new karchive library to replace KZip and KTar
...
it has to solve a few problems like:
1. blocking the current thread while listing, extracting or adding to
archive
2. lack of support for some archive formats such as 7-zip in the
previously available classes for dealing with archive
3. progress and error reporting
a KArchiveJob class may have to be implemented to solve the above
issues. the API is just as frustrating to use as KTar and KZip right now
tho and I am not happy with that but the class itself is a 3-rd rewrite
of what was once Python module, plugin for another project and now used
as base in library.
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
2022-10-06 16:53:55 +03:00