@@ -52,6 +52,7 @@ class IPAddress : public Printable {
5252// Overloaded cast operator to allow IPAddress objects to be used where a pointer
5353// to a four-byte uint8_t array is expected
5454operator uint32_t ()const {return _address.dword ; };
55+ bool operator ==(const uint32_t & addr)const {return _address.dword == addr; };
5556bool operator ==(const IPAddress& addr)const {return _address.dword == addr._address .dword ; };
5657bool operator ==(const uint8_t * addr)const ;
5758
@@ -73,6 +74,11 @@ class IPAddress : public Printable {
7374friend class DNSClient ;
7475};
7576
76- const IPAddressINADDR_NONE (0 ,0 ,0 ,0 );
77+ // Note well, it's still an unfortunate variable name as INADDR_NONE is defined
78+ // as ((in_addr_t) 0xffffffff) on Linux, *BSD and lwIP. Two definitions might
79+ // collide in unexpected ways. It's kept as zero to preserve compatibility
80+ // with previous versions of the library defining INADDR_NONE as `0.0.0.0`
81+ // and not as `255.255.255.255`.
82+ static const uint32_t INADDR_NONE (0 );
7783
7884#endif