]> git.ipfire.org Git - thirdparty/git.git/commitdiff
object-store: avoid extra ';' from KHASH_INIT
authorCarlo Marcelo Arenas Belón <carenas@gmail.com>
Mon, 9 Aug 2021 01:38:32 +0000 (18:38 -0700)
committerJunio C Hamano <gitster@pobox.com>
Mon, 9 Aug 2021 16:01:30 +0000 (09:01 -0700)
cf2dc1c238 (speed up alt_odb_usable() with many alternates, 2021-07-07)
introduces a KHASH_INIT invocation with a trailing ';', which while
commonly expected will trigger warnings with pedantic on both
clang[-Wextra-semi] and gcc[-Wpedantic], because that macro has already
a semicolon and is meant to be invoked without one.

while fixing the macro would be a worthy solution (specially considering
this is a common recurring problem), remove the extra ';' for now to
minimize churn.

Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
object-store.h

index e679acc4c31316cee2863579721e6c0f97210831..d24915ced1b2dd2aedb8300741d83372d9ea53a0 100644 (file)
@@ -34,7 +34,7 @@ struct object_directory {
 };
 
 KHASH_INIT(odb_path_map, const char * /* key: odb_path */,
-       struct object_directory *, 1, fspathhash, fspatheq);
+       struct object_directory *, 1, fspathhash, fspatheq)
 
 void prepare_alt_odb(struct repository *r);
 char *compute_alternate_path(const char *path, struct strbuf *err);