mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-02-22 14:42:40 +01:00
bkpr: duplicate the name, dont steal it
This commit is contained in:
parent
0617690981
commit
97204d6e0a
1 changed files with 3 additions and 2 deletions
|
@ -1,17 +1,18 @@
|
|||
#include "config.h"
|
||||
|
||||
#include <ccan/str/str.h>
|
||||
#include <ccan/tal/str/str.h>
|
||||
#include <common/coin_mvt.h>
|
||||
#include <common/node_id.h>
|
||||
#include <plugins/bkpr/account.h>
|
||||
|
||||
struct account *new_account(const tal_t *ctx,
|
||||
const char *name STEALS,
|
||||
const char *name,
|
||||
struct node_id *peer_id)
|
||||
{
|
||||
struct account *a = tal(ctx, struct account);
|
||||
|
||||
a->name = tal_steal(a, name);
|
||||
a->name = tal_strdup(a, name);
|
||||
a->peer_id = peer_id;
|
||||
a->is_wallet = streq(a->name, WALLET);
|
||||
a->we_opened = false;
|
||||
|
|
Loading…
Add table
Reference in a new issue