MCPcopy Create free account
hub / github.com/acl-dev/acl / run

Method run

lib_acl_cpp/samples/tcp_pool/client/main.cpp:17–33  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

15
16protected:
17 void* run(void)
18 {
19 char* s = new char[len_ + 1];
20 memset(s, 'x', len_);
21 s[len_] = 0;
22
23 for (int i = 0; i < count_; i++) {
24 if (pool_.send(s, len_) == false) {
25 printf("send to %s error %s\r\n",
26 pool_.get_addr(), acl::last_serror());
27 break;
28 }
29 }
30
31 delete []s;
32 return NULL;
33 }
34
35private:
36 acl::tcp_pool& pool_;

Callers

nothing calls this directly

Calls 3

last_serrorFunction · 0.50
sendMethod · 0.45
get_addrMethod · 0.45

Tested by

no test coverage detected