Your message dated Wed, 9 Aug 2017 22:11:10 +0100
with message-id <d826530d-d34f-4df0-ab31-99ea42993...@debian.org>
and subject line Re: Bug#866011: git: FTBFS on sparc64 due to unaligned access 
in pack-bitmap.c
has caused the Debian Bug report #866011,
regarding git: FTBFS on sparc64 due to unaligned access in pack-bitmap.c
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
immediately.)


-- 
866011: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=866011
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Source: git
Version: 1:2.13.0+next.20170520-1
Severity: important
Tags: patch upstream
User: debian-sp...@lists.debian.org
Usertags: sparc64
X-Debbugs-Cc: debian-sp...@lists.debian.org

Hi,
New tests added upstream have been causing git to FTBFS on sparc64 due
to a not-previously-noticed unaligned access in pack-bitmap. Please find
attached the patch submitted upstream (mailing list index has not yet
updated, hence the lack of a Forwarded:).

Regards,
James
From: James Clarke <jrt...@jrtc27.com>
To: gits...@pobox.com
Cc: James Clarke <jrt...@jrtc27.com>,
        g...@vger.kernel.org
Subject: [PATCH] pack-bitmap: Don't perform unaligned memory access
Date: Mon, 26 Jun 2017 16:16:12 +0100
Message-Id: <20170626151612.64019-1-jrt...@jrtc27.com>
X-Mailer: git-send-email 2.13.2

The preceding bitmap entries have a 1-byte XOR-offset and 1-byte flags,
so their size is not a multiple of 4. Thus the name-hash cache is only
guaranteed to be 2-byte aligned and so we must use get_be32 rather than
indexing the array directly.

Signed-off-by: James Clarke <jrt...@jrtc27.com>
---

This was noticed thanks to the recent tests added to t5310-pack-bitmaps.sh,
which were crashing with SIGBUS on Debian sparc64. All tests (excluding those
marked with known breakage) now pass again.

 pack-bitmap.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pack-bitmap.c b/pack-bitmap.c
index a3ac3dccd..327634cd7 100644
--- a/pack-bitmap.c
+++ b/pack-bitmap.c
@@ -627,7 +627,7 @@ static void show_objects_for_type(
                        sha1 = nth_packed_object_sha1(bitmap_git.pack, 
entry->nr);

                        if (bitmap_git.hashes)
-                               hash = ntohl(bitmap_git.hashes[entry->nr]);
+                               hash = get_be32(bitmap_git.hashes + entry->nr);

                        show_reach(sha1, object_type, 0, hash, bitmap_git.pack, 
entry->offset);
                }
--
2.13.2


--- End Message ---
--- Begin Message ---
Version: 1:2.13.2+next.20170630-1

> On 26 Jun 2017, at 16:31, James Clarke <jrt...@debian.org> wrote:
> 
> Source: git
> Version: 1:2.13.0+next.20170520-1
> Severity: important
> Tags: patch upstream
> User: debian-sp...@lists.debian.org
> Usertags: sparc64
> X-Debbugs-Cc: debian-sp...@lists.debian.org
> 
> Hi,
> New tests added upstream have been causing git to FTBFS on sparc64 due
> to a not-previously-noticed unaligned access in pack-bitmap. Please find
> attached the patch submitted upstream (mailing list index has not yet
> updated, hence the lack of a Forwarded:).

Fixed in the upload of the above version.

James

--- End Message ---

Reply via email to