static void test_fault_injection(struct pool *pop) { if (!common_fault_injection_enabled()) return; UT_ASSERTne(pop, NULL); common_inject_fault_at(PMEM_MALLOC, 1, "ctl_parse_args"); test_config_written = 0; int ret = ctl_load_config_from_string(pop->ctl, pop, "debug.test_wo=333;debug.test_rw=444;"); UT_ASSERTne(ret, 0); UT_ASSERTeq(errno, ENOMEM); }
void pmempool_inject_fault_at(enum pmem_allocation_type type, int nth, const char *at) { common_inject_fault_at(type, nth, at); }