And that is precisely why I've been gunning for getting a good CI setup in place.
The above patch worked for me flawlessly, but is causing problems on the MSVC compiler. Thanking You, Darshit Shah Sent from mobile device. Please excuse my brevity On 27-Nov-2014 11:01 pm, "Gisle Vanem" <[email protected]> wrote: > > The recent change [1] to gettext.h of replacing free() with > xfree() has generated many warnings on MSVC: > > cl -nologo -MD ... -c cookies.c > g:\mingw32\src\inet\wget\src\gettext.h(218) : warning C4013: 'xfree' undefined; > assuming extern returning int > > The cause is in "gettext.h" (the package from Hell IMHO. > "gettext.h" is included in "wget.h" before "utils.h" which > defines xfree): > #define _LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS \ > (((__GNUC__ >= 3 || __GNUG__ >= 2) && !__STRICT_ANSI__) \ > /* || __STDC_VERSION__ >= 199901L */ ) > > I.e. GNU only. So what to do? Here I just did: > @@ -176,6 +176,7 @@ > > #if !_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS > #include <stdlib.h> > +#define xfree free > #endif > That is exactly how we otherwise define xfree. Maybe the definition should be moved to a more appropriate place so that MSVC doesn't complain? > Wasn't there an alloca() discussion recently? Why not use > that instead? far more portable IMHO. > If I remember right, we decided against using alloca because of some issues with alloca.h not being available on some architectures. > [1]: 2014-11-27 Darshit Shah <[email protected]> > > * cookies.c, gettext.h, init.c, retr.c, url.c, warc.c: Replace usage of > free() with xfree() macro. > > -- > --gv > @Tim, your idea about a docker setup would really help us in these cases. See if you can set it up sometime soon. We'll hopefully incorporate it after the v1.16.1 release.
