]> git.ipfire.org Git - thirdparty/git.git/commit - config.c
config: drop cf validity check in get_next_char()
authorHeiko Voigt <hvoigt@hvoigt.net>
Sat, 11 May 2013 13:19:29 +0000 (15:19 +0200)
committerJunio C Hamano <gitster@pobox.com>
Fri, 12 Jul 2013 16:34:57 +0000 (09:34 -0700)
commitdbb9a8125542be4d57bc71b6d5baf81c7409a68b
tree0a53564f29b0b80063f104e7de92e0c6d2baab9e
parentca4b5de28bad7d50b882794124ca4e57044a1cba
config: drop cf validity check in get_next_char()

The global variable cf is set with an initialized value in all codepaths before
calling this function.

The complete call graph looks like this:

  git_config_from_file
    -> do_config_from
      -> git_parse_file
        -> get_next_char
        -> get_value
            -> get_next_char
            -> parse_value
                -> get_next_char
        -> get_base_var
            -> get_next_char
            -> get_extended_base_var
                -> get_next_char

The variable is initialized in do_config_from.

Signed-off-by: Heiko Voigt <hvoigt@hvoigt.net>
Acked-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
config.c