Steffen Prohaska <prohaska@xxxxxx> writes: > "git rev-parse --symbolic" used to return the ref name as it was > specified on the command line. This is changed to returning the > full matched ref name, i.e. "git rev-parse --symbolic master" > now typically returns "refs/heads/master". This is to expose "dwim_ref" logic, so it might be a good idea to introduce a new option --dwim-ref for this purpose. git rev-parse --symbolic master^2 is designed to give "master^2" or fail if "master" is not a merge. Similarly, you would diagnose a failure if somebody asks to show git rev-parse --dwim-ref master~4 instead of giving "refs/heads/master~4". > +static void show_rev(int type, const unsigned char *sha1, const char *name, const char* real_name) > @@ -131,7 +133,7 @@ static void show_default(void) > > def = NULL; > if (!get_sha1(s, sha1)) { > - show_rev(NORMAL, sha1, s); > + show_rev(NORMAL, sha1, s, 0); A null pointer constant in git sources is spelled "NULL" not "0". > @@ -213,6 +215,7 @@ int cmd_rev_parse(int argc, const char **argv, const char *prefix) > { > int i, as_is = 0, verify = 0; > unsigned char sha1[20]; > + char* real_name = 0; Pointer sign '*' in git sources go next to the name not the type, as: char *real_name = NULL; - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html