commit | de8118e153c5e527263086605e437ccca5d4f1ef | [log] [tgz] |
---|---|---|
author | Jeff King <peff@peff.net> | Wed Jun 18 15:57:17 2014 -0400 |
committer | Junio C Hamano <gitster@pobox.com> | Fri Jun 20 10:45:19 2014 -0700 |
tree | ec37ddbc7532f1828d4535ab375805a6f794cb7e | |
parent | 6d87780399e1196932cd5ea72f84aa90224e7402 [diff] |
use skip_prefix to avoid repeated calculations In some cases, we use starts_with to check for a prefix, and then use an already-calculated prefix length to advance a pointer past the prefix. There are no magic numbers or duplicated strings here, but we can still make the code simpler and more obvious by using skip_prefix. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>