[reSIProcate] ares_mkquery.c doesn't compile after last commit
Dario Bozzali
Dario.Bozzali at ifmgroup.it
Tue Aug 8 05:40:45 CDT 2017
Hi all,
I aligned my reSIProcate repository to origin master and I noticed that ares doesn't build anymore under Windows.
Issue has been introduced in commit 920273631b699bcaf9ea3c2c448eb9af5a924b70 (26/06/2017) due to missing MAXCDNAME definition under Windows (I tested ares_14_0.vcxproj using Visual Studio 2017 Enterprise).
1>------ Build started: Project: ares, Configuration: Debug Win32 ------
1>ares_mkquery.c
1>ares_mkquery.c(124): warning C4267: '=': conversion from 'size_t' to 'unsigned char', possible loss of data
1>ares_mkquery.c(153): error C2065: 'MAXCDNAME': undeclared identifier
1>ares_mkquery.c(153): warning C4018: '>': signed/unsigned mismatch
1>Done building project "ares_14_0.vcxproj" -- FAILED.
I don't know how we want to solve the issue.
Maybe we could change ares_mkquery.c adding definition for MAXCDNAME (as in nameser.h).
#ifndef WIN32
#include <netinet/in.h>
#ifndef __CYGWIN__
# include <arpa/nameser.h>
#endif
#else
#define MAXCDNAME 255 /* maximum compressed domain name */
#endif
Or we could change ares.h adding MAXCDNAME (after MAXHOSTNAMELEN?).
#define PACKETSZ 512
#ifndef MAXHOSTNAMELEN
#define MAXHOSTNAMELEN 256
#endif
#ifndef MAXCDNAME
#define MAXCDNAME 255 /* maximum compressed domain name */
#endif
I prefer the change in ares.h. Other comments / suggestions?
Best regards,
Dario
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://list.resiprocate.org/pipermail/resiprocate-devel/attachments/20170808/19f73304/attachment.htm>
More information about the resiprocate-devel
mailing list