[Cmake-commits] CMake branch, next, updated. v3.2.1-1685-gd4f641f

Brad King brad.king at kitware.com
Thu Apr 9 14:28:20 EDT 2015


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".

The branch, next has been updated
       via  d4f641f9b94ac64b26f3c3e06a2a66e6d3eb557a (commit)
       via  ad194ae0b1d85e5e13f1c38a20d397dabccf80e9 (commit)
      from  b38bc48c51d327d90ba4bd59a0191ded7ae4026a (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=d4f641f9b94ac64b26f3c3e06a2a66e6d3eb557a
commit d4f641f9b94ac64b26f3c3e06a2a66e6d3eb557a
Merge: b38bc48 ad194ae
Author:     Brad King <brad.king at kitware.com>
AuthorDate: Thu Apr 9 14:28:20 2015 -0400
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Thu Apr 9 14:28:20 2015 -0400

    Merge topic 'fix-libarchive-gnutar-large-ids' into next
    
    ad194ae0 libarchive: Use base-256 encoding for UID/GID like GNU tar does


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=ad194ae0b1d85e5e13f1c38a20d397dabccf80e9
commit ad194ae0b1d85e5e13f1c38a20d397dabccf80e9
Author:     Nils Gladitz <nilsgladitz at gmail.com>
AuthorDate: Wed Apr 8 19:58:08 2015 +0200
Commit:     Brad King <brad.king at kitware.com>
CommitDate: Thu Apr 9 14:27:16 2015 -0400

    libarchive: Use base-256 encoding for UID/GID like GNU tar does

diff --git a/Utilities/cmlibarchive/libarchive/archive_write_set_format_gnutar.c b/Utilities/cmlibarchive/libarchive/archive_write_set_format_gnutar.c
index 13942c1..647079d 100644
--- a/Utilities/cmlibarchive/libarchive/archive_write_set_format_gnutar.c
+++ b/Utilities/cmlibarchive/libarchive/archive_write_set_format_gnutar.c
@@ -644,18 +644,18 @@ archive_format_gnutar_header(struct archive_write *a, char h[512],
 	format_octal(archive_entry_mode(entry) & 07777,
 	    h + GNUTAR_mode_offset, GNUTAR_mode_size);
 
-	/* TODO: How does GNU tar handle large UIDs? */
-	if (format_octal(archive_entry_uid(entry),
-	    h + GNUTAR_uid_offset, GNUTAR_uid_size)) {
+	/* GNU tar supports base-256 here, so should never overflow. */
+	if (format_number(archive_entry_uid(entry), h + GNUTAR_uid_offset,
+		GNUTAR_uid_size, GNUTAR_uid_max_size)) {
 		archive_set_error(&a->archive, ERANGE,
 		    "Numeric user ID %jd too large",
 		    (intmax_t)archive_entry_uid(entry));
 		ret = ARCHIVE_FAILED;
 	}
 
-	/* TODO: How does GNU tar handle large GIDs? */
-	if (format_octal(archive_entry_gid(entry),
-	    h + GNUTAR_gid_offset, GNUTAR_gid_size)) {
+	/* GNU tar supports base-256 here, so should never overflow. */
+	if (format_number(archive_entry_gid(entry), h + GNUTAR_gid_offset,
+		GNUTAR_gid_size, GNUTAR_gid_max_size)) {
 		archive_set_error(&a->archive, ERANGE,
 		    "Numeric group ID %jd too large",
 		    (intmax_t)archive_entry_gid(entry));

-----------------------------------------------------------------------

Summary of changes:


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list