From: Junio C Hamano Date: Sat, 8 Oct 2005 21:54:41 +0000 (-0700) Subject: Give proper prototype to gitstrcasestr. X-Git-Tag: v0.99.8c~1^2~4 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=e1e9c254660244756a72ecfcfff81c15fb32a6e9;p=git.git Give proper prototype to gitstrcasestr. Borrow from NO_MMAP patch by Johannes, squelch compiler warnings by declaring gitstrcasestr() when we use it. Signed-off-by: Junio C Hamano --- diff --git a/Makefile b/Makefile index 92f0bda5..b8ca504f 100644 --- a/Makefile +++ b/Makefile @@ -246,7 +246,7 @@ ifdef NEEDS_NSL SIMPLE_LIB += -lnsl endif ifdef NO_STRCASESTR - DEFINES += -Dstrcasestr=gitstrcasestr + DEFINES += -Dstrcasestr=gitstrcasestr -DNO_STRCASESTR=1 LIB_OBJS += compat/strcasestr.o endif diff --git a/mailinfo.c b/mailinfo.c index df470bb9..cb853df9 100644 --- a/mailinfo.c +++ b/mailinfo.c @@ -9,6 +9,10 @@ #include #include +#ifdef NO_STRCASESTR +extern char *gitstrcasestr(const char *haystack, const char *needle); +#endif + static FILE *cmitmsg, *patchfile; static int keep_subject = 0;