Subject: [BUG] Segfault on git describe

From: Sylvestre Ledru <[email-masked]>
Date: Wed, 19 Mar 2014 11:48:27 +0100

Hello,

Trying to do some stats using the Firefox git repository
(https://github.com/mozilla/gecko-dev), I found a bug
on git describe. The following command will segfault:
git describe --contains a9ff31aebd6dbda82a3c733a72eeeaa0b0525b96

Please note that the Firefox history is a pretty long and this commit
date is 2001.

I experience this issue with the git version, and Debian packages
(1.9.0-1 and 2.0~next.20140214-2)

As attachment, the backtrace. I removed about 87250 calls to the
name_rev function. I guess that is a potential source of problem.

Full is available here:
http://people.mozilla.org/~sledru/bt-git-on-ff.txt (21 MB)

I am available to test patches if needed.

Thanks,
Sylvestre
PS: I am not registered, please cc me.