mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-02-02 02:44:15 +00:00
pedantic style and logging changes
This commit is contained in:
parent
93fbd7b3ba
commit
f405c62f1e
@ -102,7 +102,7 @@ namespace i2p
|
|||||||
{
|
{
|
||||||
RAND_bytes ((uint8_t *)&msgID, 4);
|
RAND_bytes ((uint8_t *)&msgID, 4);
|
||||||
htobe32buf (buf + DELIVERY_STATUS_MSGID_OFFSET, msgID);
|
htobe32buf (buf + DELIVERY_STATUS_MSGID_OFFSET, msgID);
|
||||||
htobe64buf (buf + DELIVERY_STATUS_TIMESTAMP_OFFSET, I2PD_NET_ID); // netID = 2
|
htobe64buf (buf + DELIVERY_STATUS_TIMESTAMP_OFFSET, I2PD_NET_ID);
|
||||||
}
|
}
|
||||||
m->len += DELIVERY_STATUS_SIZE;
|
m->len += DELIVERY_STATUS_SIZE;
|
||||||
m->FillI2NPMessageHeader (eI2NPDeliveryStatus);
|
m->FillI2NPMessageHeader (eI2NPDeliveryStatus);
|
||||||
|
@ -615,7 +615,7 @@ namespace data
|
|||||||
uint8_t flag = buf[64];
|
uint8_t flag = buf[64];
|
||||||
LogPrint (eLogDebug, "NetDb: DatabaseLookup for ", key, " recieved flags=", (int)flag);
|
LogPrint (eLogDebug, "NetDb: DatabaseLookup for ", key, " recieved flags=", (int)flag);
|
||||||
uint8_t lookupType = flag & DATABASE_LOOKUP_TYPE_FLAGS_MASK;
|
uint8_t lookupType = flag & DATABASE_LOOKUP_TYPE_FLAGS_MASK;
|
||||||
const uint8_t * excluded = buf + 65;
|
uint8_t * excluded = buf + 65;
|
||||||
uint32_t replyTunnelID = 0;
|
uint32_t replyTunnelID = 0;
|
||||||
if (flag & DATABASE_LOOKUP_DELIVERY_FLAG) //reply to tunnel
|
if (flag & DATABASE_LOOKUP_DELIVERY_FLAG) //reply to tunnel
|
||||||
{
|
{
|
||||||
@ -671,7 +671,12 @@ namespace data
|
|||||||
lookupType == DATABASE_LOOKUP_TYPE_NORMAL_LOOKUP))
|
lookupType == DATABASE_LOOKUP_TYPE_NORMAL_LOOKUP))
|
||||||
{
|
{
|
||||||
auto leaseSet = FindLeaseSet (ident);
|
auto leaseSet = FindLeaseSet (ident);
|
||||||
if (leaseSet && !leaseSet->IsExpired ()) // we don't send back our LeaseSets
|
if (!leaseSet)
|
||||||
|
{
|
||||||
|
// no lease set found
|
||||||
|
LogPrint(eLogDebug, "NetDb: requested LeaseSet not found ident=", ident);
|
||||||
|
}
|
||||||
|
else if (leaseSet->IsExpired ()) // we don't send back our LeaseSets
|
||||||
{
|
{
|
||||||
LogPrint (eLogDebug, "NetDb: requested LeaseSet ", key, " found");
|
LogPrint (eLogDebug, "NetDb: requested LeaseSet ", key, " found");
|
||||||
replyMsg = CreateDatabaseStoreMsg (leaseSet);
|
replyMsg = CreateDatabaseStoreMsg (leaseSet);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user