0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-10-05 23:28:53 +02:00

ircd::server: More descriptive message in this error.

This commit is contained in:
Jason Volk 2018-03-09 10:56:12 -08:00
parent 1dec67d81e
commit b1a4ca6852

View file

@ -1502,7 +1502,8 @@ ircd::server::link::discard_read()
// Shouldn't ever be hit because the read() within discard() throws // Shouldn't ever be hit because the read() within discard() throws
// the pending error like an eof. // the pending error like an eof.
log.warning("Link discarded %zu of %zu unexpected bytes", log.warning("Link to %s discarded %zu of %zu unexpected bytes",
peer? string(peer->remote) : string(remote_ipport(*socket)),
discard, discard,
discarded); discarded);
@ -1511,7 +1512,9 @@ ircd::server::link::discard_read()
if(unlikely(!discard || !discarded)) if(unlikely(!discard || !discarded))
throw assertive throw assertive
{ {
"Queue is empty and nothing to discard." "peer(%p) link(%p) queue is empty and nothing to discard.",
peer.get(),
this
}; };
} }