mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-19 07:04:22 +01:00
lightningd: have logging include an optional node_id for each entry.
A log can have a default node_id, which can be overridden on a per-entry basis. This changes the format of logging, so some tests need rework. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -621,7 +621,6 @@ new_uncommitted_channel(struct peer *peer)
|
||||
{
|
||||
struct lightningd *ld = peer->ld;
|
||||
struct uncommitted_channel *uc = tal(ld, struct uncommitted_channel);
|
||||
const char *idname;
|
||||
|
||||
uc->peer = peer;
|
||||
assert(!peer->uncommitted_channel);
|
||||
@@ -629,10 +628,8 @@ new_uncommitted_channel(struct peer *peer)
|
||||
uc->transient_billboard = NULL;
|
||||
uc->dbid = wallet_get_channel_dbid(ld->wallet);
|
||||
|
||||
idname = type_to_string(uc, struct node_id, &uc->peer->id);
|
||||
uc->log = new_log(uc, uc->peer->log_book, "%s chan #%"PRIu64":",
|
||||
idname, uc->dbid);
|
||||
tal_free(idname);
|
||||
uc->log = new_log(uc, uc->peer->log_book, &uc->peer->id,
|
||||
"chan #%"PRIu64":", uc->dbid);
|
||||
|
||||
uc->fc = NULL;
|
||||
uc->our_config.id = 0;
|
||||
|
||||
Reference in New Issue
Block a user