Jeff King
903fc7da44
name-rev: replace static buffer with strbuf
...
When name-rev needs to format an actual name, we do so into
a fixed-size buffer. That includes the actual ref tip, as
well as any traversal information. Since refs can exceed
1024 bytes, this means you can get a bogus result. E.g.,
doing:
git tag $(perl -e 'print join("/", 1..1024)')
git describe --contains HEAD^
results in ".../282/283", when it should be
".../1023/1024~1".
We can solve this by using a heap buffer. We'll use a
strbuf, which lets us write into the same buffer from our
loop without having to reallocate.
Signed-off-by: Jeff King <peff@peff.net >
2017-03-30 14:59:50 -07:00
..
2016-12-07 11:31:59 -08:00
2017-02-20 22:04:47 -08:00
2016-09-07 12:59:42 -07:00
2016-11-22 13:55:20 -08:00
2017-03-17 13:50:24 -07:00
2017-03-17 13:50:25 -07:00
2017-03-21 11:18:41 -07:00
2017-02-22 10:12:15 -08:00
2017-02-01 13:46:53 -08:00
2016-02-01 13:43:02 -08:00
2016-01-15 10:12:51 -08:00
2016-02-22 14:51:09 -08:00
2016-12-07 11:31:59 -08:00
2017-03-30 14:59:50 -07:00
2017-02-27 13:57:16 -08:00
2017-02-22 10:12:15 -08:00
2016-01-15 10:35:07 -08:00
2016-09-07 12:59:43 -07:00
2017-02-20 01:11:26 -08:00
2017-03-21 11:18:41 -07:00
2017-02-22 10:12:15 -08:00
2017-03-22 10:13:41 -07:00
2016-05-13 14:35:49 -07:00
2016-05-13 14:35:49 -07:00
2017-03-17 13:50:25 -07:00
2017-01-30 14:17:00 -08:00
2017-03-15 12:08:10 -07:00
2017-02-22 10:12:15 -08:00
2017-03-02 11:12:53 -08:00
2017-03-30 14:59:50 -07:00
2017-02-22 10:12:15 -08:00
2016-12-05 14:59:29 -08:00
2017-02-22 10:12:15 -08:00
2017-03-17 13:50:23 -07:00
2015-10-16 15:27:52 -07:00
2017-03-28 14:05:58 -07:00
2017-03-21 11:18:41 -07:00
2016-09-08 21:35:55 -07:00
2017-03-28 15:28:04 -07:00
2017-03-08 14:38:41 -08:00
2016-06-13 10:37:48 -07:00
2017-03-21 11:18:41 -07:00
2017-02-13 12:06:10 -08:00
2017-03-30 14:59:50 -07:00
2017-01-08 18:04:17 -08:00
2017-03-21 11:18:41 -07:00
2016-06-06 11:14:43 -07:00
2017-02-22 10:12:16 -08:00
2017-03-21 11:18:41 -07:00
2017-01-30 14:23:40 -08:00
2016-09-15 13:17:32 -07:00
2016-04-25 14:23:42 -07:00
2017-03-17 13:50:25 -07:00
2015-10-16 15:27:52 -07:00
2016-09-29 15:42:18 -07:00
2017-01-18 15:12:15 -08:00
2017-03-30 14:59:50 -07:00
2017-03-17 13:50:25 -07:00
2017-03-28 14:05:59 -07:00
2016-02-22 14:51:09 -08:00
2016-06-03 14:38:03 -07:00
2017-02-22 10:12:15 -08:00
2017-02-22 10:12:15 -08:00
2017-01-17 15:11:05 -08:00
2017-01-31 13:14:56 -08:00
2017-03-16 14:07:16 -07:00
2017-02-09 14:55:26 -08:00
2017-03-24 13:07:37 -07:00
2017-02-22 10:12:15 -08:00
2016-10-17 11:36:50 -07:00
2017-03-21 15:03:28 -07:00
2016-12-29 13:45:37 -08:00
2017-03-30 14:59:50 -07:00
2015-10-05 13:20:08 -07:00
2017-02-20 22:04:47 -08:00
2017-01-30 14:23:40 -08:00
2017-03-27 10:59:26 -07:00
2017-03-17 13:50:28 -07:00
2017-02-13 14:33:32 -08:00
2017-03-22 15:41:21 -07:00
2017-03-24 13:07:37 -07:00
2017-03-21 15:03:29 -07:00
2017-01-23 18:51:56 -08:00
2016-11-21 11:00:38 -08:00
2017-03-28 14:05:58 -07:00
2017-02-20 22:04:47 -08:00
2017-03-30 14:59:50 -07:00
2015-09-25 10:18:18 -07:00
2016-08-24 12:31:05 -07:00
2017-03-01 13:24:21 -08:00
2017-02-20 22:04:47 -08:00
2016-11-22 13:55:20 -08:00
2017-01-17 16:10:22 -08:00
2017-03-21 11:18:41 -07:00