]> git.ipfire.org Git - thirdparty/git.git/commit
server-info: simplify cleanup in parse_pack_def()
authorJeff King <peff@peff.net>
Fri, 5 Apr 2019 18:13:14 +0000 (14:13 -0400)
committerJunio C Hamano <gitster@pobox.com>
Tue, 16 Apr 2019 07:58:21 +0000 (16:58 +0900)
commit965cc517e57f01d8013fa7b10c1d5ce72ba3e272
tree4a2db42b783e3bf09ed63e7a57637e4ce582a921
parentb83a3089b584f622054e85b9bacbd18014259b7c
server-info: simplify cleanup in parse_pack_def()

We have two exits from the function: either we jump to the out_stale
label or not. But in both exits we repeat our cleanup, and the only
difference is our return value. Let's just use a variable for the return
value to avoid repeating ourselves.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
server-info.c