Skip to content

Commit 8203448

Browse files
committed
connectd: Add new failure mode for connetd
We need a way to indiciate failure of the batching system in connectd.
1 parent 6086d86 commit 8203448

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

common/status_levels.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,9 @@ enum status_failreason {
3737
/* Gossipd sent unknown/malformed command, or fd failed */
3838
STATUS_FAIL_GOSSIP_IO,
3939

40+
/* Connect daemon received a malformed protocol_batch_element */
41+
STATUS_FAIL_PROTO_BATCH,
42+
4043
/* Other internal error. */
4144
STATUS_FAIL_INTERNAL_ERROR,
4245
};

lightningd/subd.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -405,6 +405,9 @@ static bool log_status_fail(struct subd *sd, const u8 *msg)
405405
case STATUS_FAIL_GOSSIP_IO:
406406
name = "STATUS_FAIL_GOSSIP_IO";
407407
break;
408+
case STATUS_FAIL_PROTO_BATCH:
409+
name = "STATUS_FAIL_PROTO_BATCH";
410+
break;
408411
case STATUS_FAIL_INTERNAL_ERROR:
409412
name = "STATUS_FAIL_INTERNAL_ERROR";
410413
break;

0 commit comments

Comments
 (0)