static void rpc_commit(rpc_t* rpc, void* c) { if (cfg_commit(ctx)) { rpc->fault(c, 400, "Failed to commit the changes"); return; } }
static void sv_cfg_close(void) { if (cfg == NULL) return; if (cfg_changed) { (void) cfg_commit(cfg); cfg_changed = 0; } cfg_close(cfg); cfg = NULL; }