MCPcopy Create free account
hub / github.com/ElementsProject/lightning / wallet_channel_config_insert

Function wallet_channel_config_insert

wallet/wallet.c:1786–1797  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1784}
1785
1786static void wallet_channel_config_insert(struct wallet *w,
1787 struct channel_config *cc)
1788{
1789 struct db_stmt *stmt;
1790
1791 assert(cc->id == 0);
1792
1793 stmt = db_prepare_v2(w->db, SQL("INSERT INTO channel_configs DEFAULT VALUES;"));
1794 db_exec_prepared_v2(stmt);
1795 cc->id = db_last_insert_id_v2(stmt);
1796 tal_free(stmt);
1797}
1798
1799static void wallet_channel_config_save(struct wallet *w,
1800 const struct channel_config *cc)

Callers 2

wallet_channel_insertFunction · 0.85
test_channel_config_crudFunction · 0.85

Calls 3

db_exec_prepared_v2Function · 0.85
db_last_insert_id_v2Function · 0.85
tal_freeFunction · 0.85

Tested by 1

test_channel_config_crudFunction · 0.68