mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-23 09:04:22 +01:00
dev_disconnect: log when we are going to disconnect.
Makes it easier to figure out where we were when complex tests fail. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -2,6 +2,7 @@
|
|||||||
#include <ccan/err/err.h>
|
#include <ccan/err/err.h>
|
||||||
#include <ccan/str/str.h>
|
#include <ccan/str/str.h>
|
||||||
#include <lightningd/dev_disconnect.h>
|
#include <lightningd/dev_disconnect.h>
|
||||||
|
#include <lightningd/status.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <sys/socket.h>
|
#include <sys/socket.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
@@ -37,6 +38,7 @@ char dev_disconnect(int pkt_type)
|
|||||||
assert(dev_disconnect_fd != -1);
|
assert(dev_disconnect_fd != -1);
|
||||||
lseek(dev_disconnect_fd, strlen(dev_disconnect_line)+1, SEEK_CUR);
|
lseek(dev_disconnect_fd, strlen(dev_disconnect_line)+1, SEEK_CUR);
|
||||||
|
|
||||||
|
status_trace("dev_disconnect: %s", dev_disconnect_line);
|
||||||
return dev_disconnect_line[0];
|
return dev_disconnect_line[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user