Am 12.10.18 um 08:33 schrieb Junio C Hamano:
"Derrick Stolee via GitGitGadget" <[email protected]> writes:+struct topo_walk_info {}; + +static void init_topo_walk(struct rev_info *revs) +{ + struct topo_walk_info *info; + revs->topo_walk_info = xmalloc(sizeof(struct topo_walk_info)); + info = revs->topo_walk_info; + memset(info, 0, sizeof(struct topo_walk_info));There is no member in the struct at this point. Are we sure this is safe? Just being curious.
sizeof cannot return 0. sizeof(struct topo_walk_info) will be 1 here. -- Hannes

