MCPcopy Create free account
hub / github.com/ElementsProject/lightning / fatal_vfmt

Function fatal_vfmt

lightningd/log.c:1128–1144  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1126}
1127
1128void fatal_vfmt(const char *fmt, va_list ap)
1129{
1130 va_list ap2;
1131
1132 /* You are not allowed to re-use va_lists, so make a copy. */
1133 va_copy(ap2, ap);
1134 vfprintf(stderr, fmt, ap);
1135 fprintf(stderr, "\n");
1136
1137 if (!crashlog)
1138 exit(1);
1139
1140 logv(crashlog, LOG_BROKEN, NULL, true, fmt, ap2);
1141 abort();
1142 /* va_copy() must be matched with va_end(), even if unreachable. */
1143 va_end(ap2);
1144}
1145
1146void fatal(const char *fmt, ...)
1147{

Callers 1

fatalFunction · 0.70

Calls 2

abortFunction · 0.85
logvFunction · 0.70

Tested by

no test coverage detected