]>
git.ipfire.org Git - thirdparty/libarchive.git/log
Michihiro NAKAJIMA [Mon, 27 Jun 2011 13:24:29 +0000 (09:24 -0400)]
Fix a silly bug made by previous change: do not return a pointer address consumed.
SVN-Revision: 3435
Michihiro NAKAJIMA [Mon, 27 Jun 2011 11:59:30 +0000 (07:59 -0400)]
archive_string_conversion_to_charset() should be used for an archive writer.
SVN-Revision: 3434
Michihiro NAKAJIMA [Mon, 27 Jun 2011 11:13:21 +0000 (07:13 -0400)]
Canonicalize some charset-name so we can detect UTF-8, UTF-16BE and CP932 even if
those consist of lower alphabet characters or '-' omitted.
SVN-Revision: 3433
Michihiro NAKAJIMA [Mon, 27 Jun 2011 07:56:32 +0000 (03:56 -0400)]
Fix issue 106. The original problem happned on linux platform and I fixed it onece
in r3277 but it was not sufficient. This change consider it could happen on other
platforms that the entry object has one sparse block and it indicates the whole file
data, which sparse block is made by other program code(not only our code).
SVN-Revision: 3432
Tim Kientzle [Mon, 27 Jun 2011 00:40:08 +0000 (20:40 -0400)]
First cut at RAR support, including RARv3.
This is currently rather limited.
SVN-Revision: 3427
Tim Kientzle [Mon, 27 Jun 2011 00:30:18 +0000 (20:30 -0400)]
Rename this test to match how other tests are named.
SVN-Revision: 3426
Tim Kientzle [Sun, 26 Jun 2011 17:32:14 +0000 (13:32 -0400)]
Issue 153: Test failures on platforms that lack full support for
the various format/filter options.
SVN-Revision: 3425
Tim Kientzle [Sun, 26 Jun 2011 04:09:09 +0000 (00:09 -0400)]
Extend the --newer-than test to verify the behavior when there's a new
file inside an old directory. Rework the descent logic in write.c
somewhat to fix the behavior here.
SVN-Revision: 3424
Tim Kientzle [Sat, 25 Jun 2011 23:33:15 +0000 (19:33 -0400)]
Extend the MacOS compatibility test to verify that the attribute blob
starts with the expected bytes.
Fix the bug that this uncovered.
SVN-Revision: 3423
Tim Kientzle [Sat, 25 Jun 2011 19:30:27 +0000 (15:30 -0400)]
Extend the old test_compat_mac_gnutar to exercise compatibility with
both Apple's hacked GNU tar (<= 10.5) and Apple's hacked bsdtar (>= 10.6).
SVN-Revision: 3422
Michihiro NAKAJIMA [Sat, 25 Jun 2011 08:29:08 +0000 (04:29 -0400)]
Fix counting files read, dot not count it up when returning ARCHIVE_EOF.
Add the check of the return value of archive_file_count() into several
format reader tests.
SVN-Revision: 3421
Michihiro NAKAJIMA [Sat, 25 Jun 2011 06:34:10 +0000 (02:34 -0400)]
Fix a comment about the garbage bytes of CFDATA compressed by the deflate compression.
SVN-Revision: 3420
Colin Percival [Thu, 23 Jun 2011 10:00:27 +0000 (06:00 -0400)]
Fix typo: s/chekc sum/check sum/.
Submitted by: Ralph Corderoy (via Tarsnap)
SVN-Revision: 3418
Colin Percival [Wed, 22 Jun 2011 08:24:41 +0000 (04:24 -0400)]
Replace a pointer to an explanation which doesn't exist by the
explanation itself.
Submitted by: Ralph Corderoy, via Tarsnap
Explanation from: Tim Kientzle
Reviewed by: Tim Kientzle
SVN-Revision: 3414
Michihiro NAKAJIMA [Tue, 21 Jun 2011 08:36:26 +0000 (04:36 -0400)]
Use CoreServices framework for Mac OS X in configure.ac, the same thing in CMakeLists.txt
has been already changed.
SVN-Revision: 3412
Michihiro NAKAJIMA [Tue, 21 Jun 2011 08:19:49 +0000 (04:19 -0400)]
Remove unneeded code.
SVN-Revision: 3411
Michihiro NAKAJIMA [Tue, 21 Jun 2011 07:57:42 +0000 (03:57 -0400)]
Do no use random data for the contents of ISO image; it cannot create
the same size of an ISO imaige every time when using zisofs option.
SVN-Revision: 3410
Michihiro NAKAJIMA [Tue, 21 Jun 2011 07:37:53 +0000 (03:37 -0400)]
Fix warnings.
SVN-Revision: 3409
Michihiro NAKAJIMA [Tue, 21 Jun 2011 07:28:32 +0000 (03:28 -0400)]
Fix comment and style. no functional change.
SVN-Revision: 3408
Michihiro NAKAJIMA [Tue, 21 Jun 2011 07:17:14 +0000 (03:17 -0400)]
This is the final step to reduce use of both read() and write() system-calls in the iso9660 writer.
- Stop reading the contents of each file from the temporary file with read().
- Read the block of all file contents instead, and then write it to next stream.
SVN-Revision: 3407
Michihiro NAKAJIMA [Mon, 20 Jun 2011 12:49:13 +0000 (08:49 -0400)]
Fix making a bootable iso image with zisofs option.
SVN-Revision: 3406
Michihiro NAKAJIMA [Mon, 20 Jun 2011 07:53:18 +0000 (03:53 -0400)]
This is second step to reduce use of both read() and write() system-calls in the iso9660 writer.
- Copy file contents to wbuff, 64K buffer, and then write wbuff data with write() syscall when
the buffer is full.
- Improve wbuff handling to be able to be used for zisofs accordingly.
- Stop using wbuff as read buffer in setup_boot_information() function.
SVN-Revision: 3405
Michihiro NAKAJIMA [Sun, 19 Jun 2011 11:32:03 +0000 (07:32 -0400)]
This is first step to reduce use of both read() and write() system-calls in the iso9660 writer.
- Use only one temporary file to be simple structure.
- When enabling zisofs, almost all files except a small(<2048 bytes) file are, consequently,
always compressed even if it is a boot file. The boot file will be uncompressed later.
- Write those files to the temporary file by 2048 bytes, though currently this is no effect.
SVN-Revision: 3404
Michihiro NAKAJIMA [Thu, 16 Jun 2011 09:14:17 +0000 (05:14 -0400)]
Shift away "tar:utf8type=libarchive2x" option which is to read a pax file made with
libarchive 2.x in a wrong assumption of a wchar_t form in non UTF-8 locale;
use "tar:compat-2x" option instead.
And also add ""cpio:compat-2x" and "zip:compat-2x" to read filenames,
which are converted with CP_ACP, in those format on Windows plaform,
although you can use "hdrcharset=CP_ACP" option.
For posix like system:
- use "tar:compat-2x" option when you get incorrect filenames from pax
files made with bsdtar/libarchive 2.x.
For Windows system:
- use "tar:compat-2x", "cpio:compat-2x" and "zip:compat-2x" options
when you get incorrect filnames from those archives(except pax format)
made with bsdtar/libarchive 2.x.
SVN-Revision: 3403
Michihiro NAKAJIMA [Wed, 15 Jun 2011 10:10:01 +0000 (06:10 -0400)]
In the pax writer, do not get a filename dependent on current locale unless getting a filename in UTF-8 fails.
SVN-Revision: 3402
Michihiro NAKAJIMA [Mon, 13 Jun 2011 08:51:54 +0000 (04:51 -0400)]
Try to use "SJIS" character-set if use of "CP932" failed and a best effort bit is on,
because all of implements of iconv do not support "CP932" character-set and
"SJIS" character-set is widely supported more than "CP932".
SVN-Revision: 3401
Michihiro NAKAJIMA [Thu, 9 Jun 2011 08:50:27 +0000 (04:50 -0400)]
Clean up style; no functional change.
SVN-Revision: 3400
Michihiro NAKAJIMA [Wed, 8 Jun 2011 13:38:02 +0000 (09:38 -0400)]
Rework enabling a operation to a wrong UTF-8 string made with Libarchive 2.x.
SVN-Revision: 3399
Michihiro NAKAJIMA [Tue, 7 Jun 2011 15:49:22 +0000 (11:49 -0400)]
Set SCONV_WIN_CP flag so that we use Windows API for UTF-16BE conversion
because IsValidCodePage(CP_UTF16BE) fails but we can handle it with byte-swapping.
SVN-Revision: 3398
Michihiro NAKAJIMA [Tue, 7 Jun 2011 14:56:05 +0000 (10:56 -0400)]
Properly handle SCONV_BEST_EFFORT flag when converting UTF-16BE.
SVN-Revision: 3397
Michihiro NAKAJIMA [Tue, 7 Jun 2011 11:14:19 +0000 (07:14 -0400)]
Remove unneeded conversion code translation a string from a UTF-8 form to
the current locale because it will not happen without conversion errors.
SVN-Revision: 3396
Michihiro NAKAJIMA [Tue, 7 Jun 2011 07:25:19 +0000 (03:25 -0400)]
Make sure plenty size to an output buffer for a replacement character in UTF-8.
SVN-Revision: 3395
Michihiro NAKAJIMA [Tue, 7 Jun 2011 06:57:13 +0000 (02:57 -0400)]
Reduce duplicate code by merging strncat_from_utf16be and strncat_to_utf16be
into iconv_strncat_in_locale.
SVN-Revision: 3394
Michihiro NAKAJIMA [Sun, 5 Jun 2011 14:52:55 +0000 (10:52 -0400)]
Improve string conversion functions:
- Decide conversion functions when creating a string conversion object.
SVN-Revision: 3393
Michihiro NAKAJIMA [Wed, 1 Jun 2011 09:22:48 +0000 (05:22 -0400)]
Clean up get_sconv_object() to avoid duplicate check and simplify its code.
No functional changes.
SVN-Revision: 3392
Michihiro NAKAJIMA [Mon, 30 May 2011 08:47:00 +0000 (04:47 -0400)]
Some c compiler system provides wmemcpy as macro.
SVN-Revision: 3391
Michihiro NAKAJIMA [Mon, 30 May 2011 08:41:17 +0000 (04:41 -0400)]
Unbreak build.
SVN-Revision: 3390
Michihiro NAKAJIMA [Sun, 29 May 2011 13:32:23 +0000 (09:32 -0400)]
For Mac OS X, update comment in create_sconv_object(), and perform the normalization form C when
current locale is not UTF-8 because iconv would correctly handle filenames than those be in
UTF-8 NFD or UTF-16BE in NFD.
SVN-Revision: 3389
Michihiro NAKAJIMA [Sat, 28 May 2011 07:31:27 +0000 (03:31 -0400)]
Rework archive_string_normalize_D() function.
- improve ConvertFromUnicodeToText() handling.
- correct a buffer size for NFD string.
- return no changed data if the conversion fails.
SVN-Revision: 3388
Michihiro NAKAJIMA [Thu, 26 May 2011 10:03:16 +0000 (06:03 -0400)]
Fix expanding output string buffer on Mac OS X.
SVN-Revision: 3387
Michihiro NAKAJIMA [Thu, 26 May 2011 09:05:26 +0000 (05:05 -0400)]
Move failure() statement to right place.
SVN-Revision: 3386
Michihiro NAKAJIMA [Wed, 25 May 2011 12:01:15 +0000 (08:01 -0400)]
Fix string conversion errors on Mac OS X.
SVN-Revision: 3385
Michihiro NAKAJIMA [Wed, 25 May 2011 10:50:32 +0000 (06:50 -0400)]
Improve test_archive_string_conversion for export, a write side conversion process.
SVN-Revision: 3384
Michihiro NAKAJIMA [Tue, 24 May 2011 11:25:16 +0000 (07:25 -0400)]
Remove unneeded assignment code found with Clang Static Analyzer.
SVN-Revision: 3383
Michihiro NAKAJIMA [Tue, 24 May 2011 11:13:01 +0000 (07:13 -0400)]
Avoid warnings by Clang Static Analyzer.
SVN-Revision: 3382
Michihiro NAKAJIMA [Tue, 24 May 2011 10:48:59 +0000 (06:48 -0400)]
Fix the result code of normalization.
SVN-Revision: 3381
Michihiro NAKAJIMA [Tue, 24 May 2011 10:46:48 +0000 (06:46 -0400)]
Return a correct status when a entry has an incorrect linkname.
SVN-Revision: 3380
Michihiro NAKAJIMA [Tue, 24 May 2011 10:28:46 +0000 (06:28 -0400)]
Avoid borland warnings at test_archive_string_conversion.c.
SVN-Revision: 3379
Michihiro NAKAJIMA [Tue, 24 May 2011 10:19:31 +0000 (06:19 -0400)]
Use compress for test_archive_string_conversion.txt instead of gzip to work
a test test_archive_string_conversion on Windows platform, which does not
have zlib by default.
SVN-Revision: 3378
Michihiro NAKAJIMA [Tue, 24 May 2011 10:00:05 +0000 (06:00 -0400)]
Combine strncat_from_utf16_to_utf8 and strncat_from_utf8_to_utf16 to make
a new function archive_string_append_unicode.
SVN-Revision: 3377
Tim Kientzle [Tue, 24 May 2011 03:26:44 +0000 (23:26 -0400)]
Issue 157: Fix some unused-variable warnings from GCC 4.6.
SVN-Revision: 3376
Tim Kientzle [Tue, 24 May 2011 03:22:31 +0000 (23:22 -0400)]
Issue 157: Found by GCC 4.6: The temp buffer, which was set up
specifically to avoid walking off the end of the provided input
data, wasn't being used.
Possible ramification: libarchive could segfault when writing
shar files with uuencode encoding of file bodies, if the
data being read happened to end exactly at the end of
an allocated page.
SVN-Revision: 3375
Michihiro NAKAJIMA [Mon, 23 May 2011 09:47:28 +0000 (05:47 -0400)]
Implement normalization to a UTF-16BE string recorded in ISO9660 Joliet extensions.
SVN-Revision: 3374
Michihiro NAKAJIMA [Thu, 19 May 2011 13:50:22 +0000 (09:50 -0400)]
Eliminate a double check of remaining data.
SVN-Revision: 3373
Michihiro NAKAJIMA [Thu, 19 May 2011 13:33:51 +0000 (09:33 -0400)]
Remove unneeded code that case will not happen because strncat_from_utf16_to_utf8 will be called instead.
SVN-Revision: 3372
Michihiro NAKAJIMA [Thu, 19 May 2011 11:58:18 +0000 (07:58 -0400)]
Rework archive_strncat_in_locale mainly around UTF-16 handling to reduce duplicate code.
SVN-Revision: 3371
Michihiro NAKAJIMA [Thu, 19 May 2011 11:52:15 +0000 (07:52 -0400)]
Avoid several warnings in libarchive_test on Borland C Compiler.
SVN-Revision: 3370
Michihiro NAKAJIMA [Thu, 19 May 2011 05:22:21 +0000 (01:22 -0400)]
Fix a silly bug made by previous change.
SVN-Revision: 3369
Michihiro NAKAJIMA [Thu, 19 May 2011 04:14:02 +0000 (00:14 -0400)]
Increase a buffer size for Joliet extension names up to 1024 bytes.
It is hard to calculate MBS length for limitation check.
SVN-Revision: 3368
Michihiro NAKAJIMA [Thu, 19 May 2011 03:42:17 +0000 (23:42 -0400)]
Fix build failure in a strict check.
SVN-Revision: 3367
Michihiro NAKAJIMA [Wed, 18 May 2011 15:21:51 +0000 (11:21 -0400)]
Set UTF-16BE filenames in Joliet extension to archvie_enty directly in a string conversion, and
report the conversion error if it happened.
SVN-Revision: 3366
Michihiro NAKAJIMA [Wed, 18 May 2011 15:08:56 +0000 (11:08 -0400)]
Implement converting WCS from/to UTF-16BE on Windows, which code will be used
in ISO9660 reader and writer through archive_mstring.
SVN-Revision: 3365
Michihiro NAKAJIMA [Wed, 18 May 2011 10:42:29 +0000 (06:42 -0400)]
Fix build failure on Visual Studio.
SVN-Revision: 3364
Michihiro NAKAJIMA [Wed, 18 May 2011 09:13:57 +0000 (05:13 -0400)]
Fix warnings in libarchive/test_*.c on Borland C Compiler.
SVN-Revision: 3363
Michihiro NAKAJIMA [Wed, 18 May 2011 07:34:31 +0000 (03:34 -0400)]
Comment out unneeded code in test_write_format_zip_no_compression.
SVN-Revision: 3362
Michihiro NAKAJIMA [Wed, 18 May 2011 05:27:40 +0000 (01:27 -0400)]
Change a type of UTF-8 byte counter table to avoid warnings on Borland C Compiler.
SVN-Revision: 3361
Michihiro NAKAJIMA [Wed, 18 May 2011 05:13:01 +0000 (01:13 -0400)]
Remove debug code for Mac OS.
SVN-Revision: 3360
Michihiro NAKAJIMA [Wed, 18 May 2011 05:08:35 +0000 (01:08 -0400)]
Use NFD string for Mac OS at test_read_format_zip_filename.
SVN-Revision: 3359
Michihiro NAKAJIMA [Wed, 18 May 2011 04:54:27 +0000 (00:54 -0400)]
Redefine SCONV_* flags used for archive_string_conv object.
SVN-Revision: 3358
Michihiro NAKAJIMA [Tue, 17 May 2011 10:49:00 +0000 (06:49 -0400)]
It seems Mac OS cannot convert U+1109A, U+1109C and U+110AB to NFD although that is undocumented as far as I know.
SVN-Revision: 3357
Michihiro NAKAJIMA [Tue, 17 May 2011 10:43:02 +0000 (06:43 -0400)]
Do not use WideCharToMultiByte and MultiByteToWideChar when current locale is "C" on Windows.
SVN-Revision: 3356
Michihiro NAKAJIMA [Tue, 17 May 2011 10:41:03 +0000 (06:41 -0400)]
Properly free struct isofile object when some fatal error happened.
SVN-Revision: 3355
Michihiro NAKAJIMA [Tue, 17 May 2011 09:43:45 +0000 (05:43 -0400)]
Reduce the effect of current locale for Joliet extension name(UTF-16BE) by direct generating it from archive_entry.
SVN-Revision: 3354
Michihiro NAKAJIMA [Tue, 17 May 2011 09:08:49 +0000 (05:08 -0400)]
Fix counting UTF-16 characters and converting UTF-16 on Windows.
SVN-Revision: 3353
Michihiro NAKAJIMA [Tue, 17 May 2011 04:26:51 +0000 (00:26 -0400)]
Use assertEqualUTF8String instead of assertEqualString at test_read_format_zip_filename_UTF8_UTF8.
SVN-Revision: 3352
Michihiro NAKAJIMA [Tue, 17 May 2011 04:17:46 +0000 (00:17 -0400)]
Avoid warnings about no argument.
SVN-Revision: 3351
Michihiro NAKAJIMA [Tue, 17 May 2011 04:11:15 +0000 (00:11 -0400)]
Avoid warnings in test_archive_read_open2.c about unused variables.
SVN-Revision: 3350
Michihiro NAKAJIMA [Tue, 17 May 2011 04:03:53 +0000 (00:03 -0400)]
Avoid a warning in zip reader on Borland C Compiler.
SVN-Revision: 3349
Michihiro NAKAJIMA [Tue, 17 May 2011 03:59:00 +0000 (23:59 -0400)]
Remove unneeded code in cab reader.
SVN-Revision: 3348
Michihiro NAKAJIMA [Tue, 17 May 2011 03:55:26 +0000 (23:55 -0400)]
Move macros in archive_string.c to the top of the file.
Use macro for set byte sequence of U+FFFD for UTF-8.
SVN-Revision: 3347
Michihiro NAKAJIMA [Tue, 17 May 2011 03:19:07 +0000 (23:19 -0400)]
Rework UTF-16 conversion functions.
- rename strncpy_from_utf16be to strncat_from_utf16be and its feature is slightly changed as strcat.
- rename strncpy_to_utf16be to strncat_to_utf16be and its feature is slightly changed as strcat.
- use U+FFFD for invalid character if destination charset is UTF-8.
- proper handle surrogate pair on Windows version.
SVN-Revision: 3346
Michihiro NAKAJIMA [Mon, 16 May 2011 11:52:47 +0000 (07:52 -0400)]
Rework a handling of memory allocation failure in string conversion;
report the failure to the caller as much as we can instead of calling __archive_errx().
SVN-Revision: 3345
Michihiro NAKAJIMA [Mon, 16 May 2011 07:31:55 +0000 (03:31 -0400)]
Fix segmentation fault on Mac OS.
SVN-Revision: 3344
Michihiro NAKAJIMA [Mon, 16 May 2011 04:37:47 +0000 (00:37 -0400)]
Fix the warning Boarland C compiler complains of and some style.
SVN-Revision: 3343
Michihiro NAKAJIMA [Mon, 16 May 2011 04:28:32 +0000 (00:28 -0400)]
Clean up the code Borland C compiler complains of at cab reader.
SVN-Revision: 3342
Michihiro NAKAJIMA [Mon, 16 May 2011 04:18:20 +0000 (00:18 -0400)]
ctime and ctime_nanos are not used in set_times() on Windows.
SVN-Revision: 3341
Michihiro NAKAJIMA [Mon, 16 May 2011 04:07:59 +0000 (00:07 -0400)]
Avoid some warnings on Borland C compiler.
SVN-Revision: 3340
Michihiro NAKAJIMA [Mon, 16 May 2011 03:51:26 +0000 (23:51 -0400)]
Proper prototype for get_current_codepage and get_current_oemcp; Borland C compiler complains of this.
SVN-Revision: 3339
Michihiro NAKAJIMA [Mon, 16 May 2011 03:44:15 +0000 (23:44 -0400)]
Fix the return code of archive_string_append_from_wcs_in_codepage().
SVN-Revision: 3338
Michihiro NAKAJIMA [Mon, 16 May 2011 03:38:55 +0000 (23:38 -0400)]
Remove unused wmemcpy definition.
SVN-Revision: 3337
Michihiro NAKAJIMA [Mon, 16 May 2011 03:38:15 +0000 (23:38 -0400)]
Use wmemcpy at archive_wstring_append().
SVN-Revision: 3336
Michihiro NAKAJIMA [Sun, 15 May 2011 15:21:42 +0000 (11:21 -0400)]
Remove unneeded code in archive_write_set_format_cpio.c
SVN-Revision: 3335
Michihiro NAKAJIMA [Sun, 15 May 2011 15:20:17 +0000 (11:20 -0400)]
Remove unneeded code in archive_write_set_format_cpio_newc.c
SVN-Revision: 3334
Michihiro NAKAJIMA [Sun, 15 May 2011 14:39:47 +0000 (10:39 -0400)]
Use en_US.UTF-8 locale for tests instead of ru_RU.UTF-8 or ja_JP.UTF-8
since some platform do not install those locales by default.
SVN-Revision: 3333
Michihiro NAKAJIMA [Sun, 15 May 2011 14:08:23 +0000 (10:08 -0400)]
Detect readlinkat() on linux by CMake; linux requires fcntl.h for AT_FDCWD.
SVN-Revision: 3332
Michihiro NAKAJIMA [Sun, 15 May 2011 14:04:30 +0000 (10:04 -0400)]
Fix build failure.
SVN-Revision: 3331
Michihiro NAKAJIMA [Sun, 15 May 2011 11:41:02 +0000 (07:41 -0400)]
Improve string conversion functions of UTF-16 about invalid characters.
SVN-Revision: 3330
Michihiro NAKAJIMA [Sun, 15 May 2011 08:11:38 +0000 (04:11 -0400)]
Properly check if archive_string_ensure() succeeded or not.
SVN-Revision: 3329
Michihiro NAKAJIMA [Sun, 15 May 2011 08:01:59 +0000 (04:01 -0400)]
Apparently, both input and output data type should be UTF-16 for ConvertFromUnicodeToText()
when converting NFC to NFD.
SVN-Revision: 3328
Michihiro NAKAJIMA [Sun, 15 May 2011 06:14:55 +0000 (02:14 -0400)]
Avoid local conversion code in iso9660 writer.
SVN-Revision: 3327