MCPcopy Create free account
hub / github.com/WaykiChain/WaykiChain / GetRandAddress

Function GetRandAddress

src/tests/pressure_tests.cpp:35–45  ·  view source on GitHub ↗

* 获取随机账户地址 */

Source from the content-addressed store, hash-verified

33 * 获取随机账户地址
34 */
35map<string, string>::iterator GetRandAddress() {
36// srand(time(NULL));
37 unsigned char cType;
38 RAND_bytes(&cType, sizeof(cType));
39 int iIndex = (cType % 3);
40 map<string, string>::iterator iterAddress = mapAddress.begin();
41 while(iIndex--) {
42 ++iterAddress;
43 }
44 return iterAddress;
45}
46
47/**
48 * 获取随机的交易类型

Callers 5

CreateRegAcctTxMethod · 0.85
CallContractTxMethod · 0.85
CreateRegScriptTxMethod · 0.85
CreateRandTxMethod · 0.85
BOOST_FIXTURE_TEST_CASEFunction · 0.85

Calls 1

beginMethod · 0.45

Tested by

no test coverage detected