In the /src/net.cpp, the functoin void CConnman::PushMessage(CNode* pnode, CSerializedNetMsg&& msg) will be called frequently. The following code used inside function: ...... if (gArgs.GetBoolArg("-capturemessages", false)) { CaptureMessage(pnode->addr, msg.m_type, msg.data, /is_incoming=/false); } ...... My question is : the GetBoolArg can be called once when the class is initialized.
About frequently calling the function GetBoolArg to get parameters #24475
issue guoyl opened this issue on March 5, 2022-
guoyl commented at 8:17 AM on March 5, 2022: none
-
MarcoFalke commented at 10:42 AM on March 5, 2022: member
Yes, it can be called once. However, the impact should be minimal, as writing to disk takes more time than a map lookup.
- MarcoFalke closed this on Mar 7, 2022
- DrahtBot locked this on Mar 7, 2023
Contributors