Browse Source

Merge pull request #1705 from rex4539/typos

Fix typos
pull/1707/head
R4SAS 3 years ago committed by GitHub
parent
commit
174983548d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      libi2pd/Crypto.h
  2. 4
      libi2pd/Garlic.cpp
  3. 4
      libi2pd/NTCP2.cpp
  4. 4
      libi2pd/NetDb.cpp
  5. 2
      libi2pd/SSUSession.cpp
  6. 2
      libi2pd/Streaming.cpp
  7. 4
      libi2pd/Streaming.h
  8. 2
      libi2pd/TunnelEndpoint.cpp
  9. 2
      libi2pd/TunnelEndpoint.h
  10. 2
      libi2pd_client/BOB.h
  11. 2
      libi2pd_client/I2PTunnel.cpp
  12. 2
      libi2pd_client/SAM.cpp
  13. 2
      libi2pd_wrapper/api.swigcxx

2
libi2pd/Crypto.h

@ -106,7 +106,7 @@ namespace crypto @@ -106,7 +106,7 @@ namespace crypto
BN_CTX * m_Ctx;
uint8_t m_PrivateKey[32];
#endif
bool m_IsElligatorIneligible = false; // true if definitly ineligible
bool m_IsElligatorIneligible = false; // true if definitely ineligible
};
// ElGamal

4
libi2pd/Garlic.cpp

@ -271,7 +271,7 @@ namespace garlic @@ -271,7 +271,7 @@ namespace garlic
(*numCloves)++;
}
}
if (msg) // clove message ifself if presented
if (msg) // clove message itself if presented
{
size += CreateGarlicClove (payload + size, msg, m_Destination ? m_Destination->IsDestination () : false);
(*numCloves)++;
@ -542,7 +542,7 @@ namespace garlic @@ -542,7 +542,7 @@ namespace garlic
auto session = std::make_shared<ECIESX25519AEADRatchetSession> (this, false); // incoming
if (!session->HandleNextMessage (buf, length, nullptr, 0))
{
// try to gererate more tags for last tagset
// try to generate more tags for last tagset
if (m_LastTagset && (m_LastTagset->GetNextIndex () - m_LastTagset->GetTrimBehind () < 3*ECIESX25519_MAX_NUM_GENERATED_TAGS))
{
uint64_t missingTag; memcpy (&missingTag, buf, 8);

4
libi2pd/NTCP2.cpp

@ -681,7 +681,7 @@ namespace transport @@ -681,7 +681,7 @@ namespace transport
auto addr = ri.GetNTCP2AddressWithStaticKey (m_Establisher->m_RemoteStaticKey);
if (!addr)
{
LogPrint (eLogError, "NTCP2: No NTCP2 address wth static key found in SessionConfirmed");
LogPrint (eLogError, "NTCP2: No NTCP2 address with static key found in SessionConfirmed");
Terminate ();
return;
}
@ -973,7 +973,7 @@ namespace transport @@ -973,7 +973,7 @@ namespace transport
{
// allocate send buffer
m_NextSendBuffer = new uint8_t[287]; // can be any size > 16, we just allocate 287 frequently
// crate padding block
// create padding block
auto paddingLen = CreatePaddingBlock (totalLen, m_NextSendBuffer, 287 - 16);
// and padding block to encrypt and send
if (paddingLen)

4
libi2pd/NetDb.cpp

@ -1261,7 +1261,7 @@ namespace data @@ -1261,7 +1261,7 @@ namespace data
return it->second;
it++;
}
// still not found, try from the begining
// still not found, try from the beginning
it = m_RouterInfos.begin ();
while (it != it1 && it != m_RouterInfos.end ())
{
@ -1269,7 +1269,7 @@ namespace data @@ -1269,7 +1269,7 @@ namespace data
return it->second;
it++;
}
// still not found, try to the begining
// still not found, try to the beginning
it = it2;
while (it != m_RouterInfos.end ())
{

2
libi2pd/SSUSession.cpp

@ -1020,7 +1020,7 @@ namespace transport @@ -1020,7 +1020,7 @@ namespace transport
void SSUSession::ProcessPeerTest (const uint8_t * buf, size_t len, const boost::asio::ip::udp::endpoint& senderEndpoint)
{
uint32_t nonce = bufbe32toh (buf); // 4 bytes
boost::asio::ip::address addr; // Alice's addresss
boost::asio::ip::address addr; // Alice's address
uint16_t port = 0; // and port
auto size = ExtractIPAddressAndPort (buf + 4, len - 4, addr, port);
if (port && (size != 7) && (size != 19))

2
libi2pd/Streaming.cpp

@ -102,7 +102,7 @@ namespace stream @@ -102,7 +102,7 @@ namespace stream
LogPrint (eLogDebug, "Streaming: Stream deleted");
}
void Stream::Terminate (bool deleteFromDestination) // shoudl be called from StreamingDestination::Stop only
void Stream::Terminate (bool deleteFromDestination) // should be called from StreamingDestination::Stop only
{
m_Status = eStreamStatusTerminated;
m_AckSendTimer.cancel ();

4
libi2pd/Streaming.h

@ -111,7 +111,7 @@ namespace stream @@ -111,7 +111,7 @@ namespace stream
buf = new uint8_t[len];
memcpy (buf, b, len);
}
SendBuffer (size_t l): // creat empty buffer
SendBuffer (size_t l): // create empty buffer
len(l), offset (0)
{
buf = new uint8_t[len];
@ -366,7 +366,7 @@ namespace stream @@ -366,7 +366,7 @@ namespace stream
handler (boost::asio::error::make_error_code (boost::asio::error::timed_out), received);
else
{
// itermediate iterrupt
// itermediate interrupt
SendUpdatedLeaseSet (); // send our leaseset if applicable
AsyncReceive (buffer, handler, remainingTimeout);
}

2
libi2pd/TunnelEndpoint.cpp

@ -30,7 +30,7 @@ namespace tunnel @@ -30,7 +30,7 @@ namespace tunnel
m_NumReceivedBytes += TUNNEL_DATA_MSG_SIZE;
uint8_t * decrypted = msg->GetPayload () + 20; // 4 + 16
uint8_t * zero = (uint8_t *)memchr (decrypted + 4, 0, TUNNEL_DATA_ENCRYPTED_SIZE - 4); // witout 4-byte checksum
uint8_t * zero = (uint8_t *)memchr (decrypted + 4, 0, TUNNEL_DATA_ENCRYPTED_SIZE - 4); // without 4-byte checksum
if (zero)
{
uint8_t * fragment = zero + 1;

2
libi2pd/TunnelEndpoint.h

@ -49,7 +49,7 @@ namespace tunnel @@ -49,7 +49,7 @@ namespace tunnel
void HandleFollowOnFragment (uint32_t msgID, bool isLastFragment, uint8_t fragmentNum, const uint8_t * fragment, size_t size);
bool ConcatFollowOnFragment (TunnelMessageBlockEx& msg, const uint8_t * fragment, size_t size) const; // true if success
void HandleCurrenMessageFollowOnFragment (const uint8_t * frgament, size_t size, bool isLastFragment);
void HandleCurrenMessageFollowOnFragment (const uint8_t * fragment, size_t size, bool isLastFragment);
void HandleNextMessage (const TunnelMessageBlock& msg);
void AddOutOfSequenceFragment (uint32_t msgID, uint8_t fragmentNum, bool isLastFragment, const uint8_t * fragment, size_t size);

2
libi2pd_client/BOB.h

@ -63,7 +63,7 @@ namespace client @@ -63,7 +63,7 @@ namespace client
const char BOB_HELP_OUTPORT[] = "outport <PORT_NUMBER> - Set the outbound port that nickname contacts.";
const char BOB_HELP_INHOST[] = "inhost <HOSTNAME|IP> - Set the inbound hostname or IP.";
const char BOB_HELP_INPORT[] = "inport <PORT_NUMBER> - Set the inbound port number nickname listens on.";
const char BOB_HELP_QUIET[] = "quiet <True|False> - Wether to send the incoming destination.";
const char BOB_HELP_QUIET[] = "quiet <True|False> - Whether to send the incoming destination.";
const char BOB_HELP_LOOKUP[] = "lookup <I2P_HOSTNAME> - Look up an I2P hostname.";
const char BOB_HELP_CLEAR[] = "clear - Clear the current nickname out of the list.";
const char BOB_HELP_LIST[] = "list - List all tunnels.";

2
libi2pd_client/I2PTunnel.cpp

@ -205,7 +205,7 @@ namespace client @@ -205,7 +205,7 @@ namespace client
}
else // closed by peer
{
// get remaning data
// get remaining data
auto len = m_Stream->ReadSome (m_StreamBuffer, I2P_TUNNEL_CONNECTION_BUFFER_SIZE);
if (len > 0) // still some data
Write (m_StreamBuffer, len);

2
libi2pd_client/SAM.cpp

@ -936,7 +936,7 @@ namespace client @@ -936,7 +936,7 @@ namespace client
else // closed by peer
{
uint8_t * buff = new uint8_t[SAM_SOCKET_BUFFER_SIZE];
// get remaning data
// get remaining data
auto len = m_Stream->ReadSome (buff, SAM_SOCKET_BUFFER_SIZE);
if (len > 0) // still some data
{

2
libi2pd_wrapper/api.swigcxx

@ -1,4 +1,4 @@ @@ -1,4 +1,4 @@
// See swig.org for more inteface options,
// See swig.org for more interface options,
// e.g. map std::string to Go string
%{

Loading…
Cancel
Save