mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-12-06 19:41:15 +01:00
Fix 8447: use %u to format circid_t.
Now that circid_t is 4 bytes long, the default integer promotions will
leave it alone when sizeof(int) == 4, which will leave us formatting an
unsigned as an int. That's technically undefined behavior.
Fixes bug 8447 on bfffc1f0fc. Bug not
in any released Tor.
This commit is contained in:
+2
-3
@@ -11,7 +11,6 @@
|
||||
*
|
||||
* Right now, we only use this for processing onionskins.
|
||||
**/
|
||||
|
||||
#include "or.h"
|
||||
#include "buffers.h"
|
||||
#include "channel.h"
|
||||
@@ -341,8 +340,8 @@ connection_cpu_process_inbuf(connection_t *conn)
|
||||
circ = NULL;
|
||||
log_debug(LD_OR,
|
||||
"Unpacking cpuworker reply, chan_id is " U64_FORMAT
|
||||
", circ_id is %d",
|
||||
U64_PRINTF_ARG(chan_id), circ_id);
|
||||
", circ_id is %u",
|
||||
U64_PRINTF_ARG(chan_id), (unsigned)circ_id);
|
||||
p_chan = channel_find_by_global_id(chan_id);
|
||||
|
||||
if (p_chan)
|
||||
|
||||
Reference in New Issue
Block a user