Re: INADDR_NONE' undeclared in Squid 1.0.17

From: Jens Elkner <elkner@dont-contact.us>
Date: Fri, 27 Sep 1996 17:47:38 +0200 (MET DST)

'Andreas Jung wrote:'
>
>
> Compilation of Squid 1.0.17 under Solaris 2.5 with gcc breaks
> with the following error message:
>
> cachemgr.c: In function `client_comm_connect':
> cachemgr.c:851: `INADDR_NONE' undeclared (first use this function)
> cachemgr.c:851: (Each undeclared identifier is reported only once
> cachemgr.c:851: for each function it appears in.)
>
> Former version of Squid did not show this error messages. I think
> the value of INADDR_NONE should be :
>
> netinet/in.h:#define INADDR_NONE 0xffffffff
> (Output of in.h under SunOS)

=================================simple patch starts here============
*** cachemgr.c~ Tue Sep 24 22:16:39 1996
--- cachemgr.c Fri Sep 27 05:03:05 1996
***************
*** 198,203 ****
--- 198,207 ----
  #include "ansiproto.h"
  #include "util.h"
  
+ #ifndef INADDR_NONE
+ #define INADDR_NONE ((unsigned long) -1)
+ #endif
+
  #define MAX_ENTRIES 10000
  
  #ifndef FALSE
=================================simple patch ends=============

Have fun,
Jens.

-- 
+--------------------------------------------------------------------------+
| Jens Elkner                   | Otto-von-Guericke-Universitaet Magdeburg |
|                               +==========================================|
| Am Uniplatz 5                     elkner@irb.cs.uni-magdeburg.de         |
| WH 4   PF 310                     elkner@sunpool.cs.uni-magdeburg.de     |
| 39106 Magdeburg   GERMANY       http://irb.cs.uni-magdeburg.de/~elkner   |
+--------------------------------------------------------------------------+
Received on Fri Sep 27 1996 - 08:51:44 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:33:05 MST