From: Rusty Russell Date: Wed, 24 Feb 2010 03:42:22 +0000 (+1030) Subject: asort: fix gcc warning. X-Git-Url: http://git.ozlabs.org/?p=ccan;a=commitdiff_plain;h=e96830aefad171590e1b803f90364894db0c76de;ds=inline asort: fix gcc warning. --- diff --git a/ccan/asort/asort.c b/ccan/asort/asort.c index cf8d8d9d..3f7b7fd6 100644 --- a/ccan/asort/asort.c +++ b/ccan/asort/asort.c @@ -7,8 +7,8 @@ void _asort(void *base, size_t nmemb, size_t size, { #if HAVE_NESTED_FUNCTIONS /* This gives bogus "warning: no previous prototype for ‘cmp’" - * with gcc 4 with -Wmissing-prototypes. But there's no way - * to predeclare it, so we lose. */ + * with gcc 4 with -Wmissing-prototypes. Hence the auto crap. */ + auto int cmp(const void *a, const void *b); int cmp(const void *a, const void *b) { return compar(a, b, ctx);