mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-12-06 19:41:15 +01:00
Die if tor_vasprintf fails in connection_printf_to_buf
tor_asprintf already asserts if it fails.
This commit is contained in:
committed by
Nick Mathewson
parent
b70a0a4375
commit
8aad677bb7
+2
-2
@@ -503,8 +503,8 @@ connection_printf_to_buf(control_connection_t *conn, const char *format, ...)
|
||||
va_end(ap);
|
||||
|
||||
if (len < 0) {
|
||||
log_warn(LD_BUG, "Unable to format string for controller.");
|
||||
return;
|
||||
log_err(LD_BUG, "Unable to format string for controller.");
|
||||
tor_assert(0);
|
||||
}
|
||||
|
||||
connection_write_to_buf(buf, (size_t)len, TO_CONN(conn));
|
||||
|
||||
Reference in New Issue
Block a user