lightningd/log: clean up nomenclature.

`struct log` becomes `struct logger`, and the member which points to the
`struct log_book` becomes `->log_book` not `->lr`.

Also, we don't need to keep the log_book in struct plugin, since it has
access to ld's log_book.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2023-07-16 15:26:52 +09:30
parent 19d80e1f08
commit c074fe050f
37 changed files with 254 additions and 256 deletions

View File

@@ -105,14 +105,14 @@ void towire_node_id(u8 **pptr UNNEEDED, const struct node_id *id UNNEEDED)
int main(int argc, char *argv[])
{
struct log_book *lb;
struct log *l;
struct logger *l;
common_setup(argv[0]);
lb = new_log_book(NULL,
(sizeof(struct log_entry) + sizeof("test XXXXXX"))
*100);
l = new_log(lb, lb, NULL, "test %s", "prefix");
l = new_logger(lb, lb, NULL, "test %s", "prefix");
assert(streq(log_prefix(l), "test prefix"));