MCPcopy Create free account
hub / github.com/apache/brpc / usleep_thread_impl

Function usleep_thread_impl

test/bthread_key_unittest.cpp:439–447  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

437}
438
439static void usleep_thread_impl(PoolData2* data) {
440 if (NULL == bthread_getspecific(data->key)) {
441 PoolData2* data_new = new PoolData2();
442 ASSERT_EQ(0, bthread_setspecific(data->key, data_new));
443 }
444 bthread_usleep(1000L);
445 int length = get_thread_local_keytable_list_length(&test_pool);
446 ASSERT_LE((size_t)length, bthread::FLAGS_key_table_list_size);
447}
448
449static void* usleep_thread(void* args) {
450 usleep_thread_impl((PoolData2*)args);

Callers 1

usleep_threadFunction · 0.85

Calls 4

bthread_getspecificFunction · 0.85
bthread_setspecificFunction · 0.85
bthread_usleepFunction · 0.85

Tested by

no test coverage detected