mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-02-02 11:04:00 +01:00
assign correct 6 or 4 cap to unpublished address
This commit is contained in:
parent
94ca2514af
commit
bb5ed0b40c
|
@ -529,8 +529,8 @@ namespace data
|
||||||
WriteString ("caps", properties);
|
WriteString ("caps", properties);
|
||||||
properties << '=';
|
properties << '=';
|
||||||
std::string caps;
|
std::string caps;
|
||||||
if (address.caps & AddressCaps::eV4) caps += CAPS_FLAG_V4;
|
if (address.IsV4 ()) caps += CAPS_FLAG_V4;
|
||||||
if (address.caps & AddressCaps::eV6) caps += CAPS_FLAG_V6;
|
if (address.IsV6 ()) caps += CAPS_FLAG_V6;
|
||||||
if (caps.empty ()) caps += CAPS_FLAG_V4;
|
if (caps.empty ()) caps += CAPS_FLAG_V4;
|
||||||
WriteString (caps, properties);
|
WriteString (caps, properties);
|
||||||
properties << ';';
|
properties << ';';
|
||||||
|
@ -564,8 +564,8 @@ namespace data
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (address.caps & AddressCaps::eV4) caps += CAPS_FLAG_V4;
|
if (address.IsV4 ()) caps += CAPS_FLAG_V4;
|
||||||
if (address.caps & AddressCaps::eV6) caps += CAPS_FLAG_V6;
|
if (address.IsV6 ()) caps += CAPS_FLAG_V6;
|
||||||
if (caps.empty ()) caps += CAPS_FLAG_V4;
|
if (caps.empty ()) caps += CAPS_FLAG_V4;
|
||||||
}
|
}
|
||||||
WriteString (caps, properties);
|
WriteString (caps, properties);
|
||||||
|
|
Loading…
Reference in a new issue