mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-03-07 06:09:42 +00:00
assign correct 6 or 4 cap to unpublished address
This commit is contained in:
@@ -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);
|
||||||
|
|||||||
Reference in New Issue
Block a user