]> git.ipfire.org Git - thirdparty/krb5.git/commitdiff
Add MAXHOSTNAME guard in Windows public header 1194/head
authorVipul Mehta <vipulmehta.1989@gmail.com>
Mon, 31 May 2021 06:45:07 +0000 (12:15 +0530)
committerGreg Hudson <ghudson@mit.edu>
Thu, 3 Jun 2021 17:19:25 +0000 (13:19 -0400)
The ACE library defines a MAXHOSTNAMELEN macro, which conflicts if a
source file includes headers from both libraries.

ticket: 9010 (new)

src/include/win-mac.h

index dc0f2a1ae6d501eccbbc9c0bf9b72c9d996cd37b..0fd3a29e5f14e3c8d0060a5d2dcaec89c419bf03 100644 (file)
@@ -101,7 +101,10 @@ typedef _W64 int         ssize_t;
 #endif
 #endif /* KRB5_SYSTYPES__ */
 
+#ifndef MAXHOSTNAMELEN
 #define MAXHOSTNAMELEN  512
+#endif
+
 #ifndef MAXPATHLEN
 #define MAXPATHLEN      256            /* Also for Windows temp files */
 #endif