Skip to content
Snippets Groups Projects
Guillaume Roguez's avatar
Guillaume Roguez authored
Comparing two IP was broken.
If you try "ip1 != ip2" this always return false whatever be
ip1 and ip2.
The operator!= is not called in fact, because ip1 and ip2 were
converted by operator bool() first!

This patch resolves that by:
- mark explicit operator bool()
- declare operator!= as the opposite of operator==

Note: these latest operators have been externalized of the class
as a good C++ practice.

Change-Id: I65d01c391d3871e92bd0d2a49cad3cfa62f698cf
Tuleap: #662
ef5447e3
History
Name Last commit Last update