show-branch: use skip_prefix to drop magic numbers
commitd3cc5f4c44eeacca556f9ae0972837a84e72f288
authorJeff King <peff@peff.net>
Wed, 15 Feb 2017 21:40:52 +0000 (15 16:40 -0500)
committerJunio C Hamano <gitster@pobox.com>
Wed, 15 Feb 2017 21:50:31 +0000 (15 13:50 -0800)
tree9c3fee20aa69e546af697fcc4b2063ba6ba9d421
parentd9e557a320bd4695bccad873e176562489b2d199
show-branch: use skip_prefix to drop magic numbers

We make several starts_with() calls, only to advance
pointers. This is exactly what skip_prefix() is for, which
lets us avoid manually-counted magic numbers.

Helped-by: Pranit Bauva <pranit.bauva@gmail.com>
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/show-branch.c