From: David Hildenbrand Subject: Re: [kvm-unit-tests PATCH] Include util.h to check the prototype with the implementation Date: Tue, 27 Jun 2017 10:40:18 +0200 Message-ID: <4d652dfb-764b-c22e-3633-3d19096b7263@redhat.com> References: <1498540718-3224-1-git-send-email-thuth@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Cc: Paolo Bonzini , =?UTF-8?B?UmFkaW0gS3LEjW3DocWZ?= To: Thomas Huth , kvm@vger.kernel.org Return-path: Received: from mx1.redhat.com ([209.132.183.28]:51194 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751483AbdF0IkZ (ORCPT ); Tue, 27 Jun 2017 04:40:25 -0400 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 605C27CE0E for ; Tue, 27 Jun 2017 08:40:20 +0000 (UTC) In-Reply-To: <1498540718-3224-1-git-send-email-thuth@redhat.com> Content-Language: en-US Sender: kvm-owner@vger.kernel.org List-ID: On 27.06.2017 07:18, Thomas Huth wrote: > util.c should include util.h so that the compiler can check that > the prototype from the header matches the implementation. This is > required for compiling the file with "-Wmissing-prototypes". Why is something like that not contained in -Wextra? ;) > > Signed-off-by: Thomas Huth > --- > lib/util.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/lib/util.c b/lib/util.c > index 69b1810..a905541 100644 > --- a/lib/util.c > +++ b/lib/util.c > @@ -4,6 +4,7 @@ > * This work is licensed under the terms of the GNU LGPL, version 2. > */ > #include > +#include "util.h" > > int parse_keyval(char *s, long *val) > { > Reviewed-by: David Hildenbrand -- Thanks, David