From 98c088fced8486ffe0208d9bb09d2496823459af Mon Sep 17 00:00:00 2001 From: Richard Fuchs Date: Wed, 6 Aug 2025 10:59:31 -0400 Subject: [PATCH] MT#55283 silence asan warning Change-Id: I131e51fc826a52fb571e78f09aea3aa99e9e7e1f --- lib/bencode.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/bencode.h b/lib/bencode.h index 8c60b2725..464e672da 100644 --- a/lib/bencode.h +++ b/lib/bencode.h @@ -380,6 +380,9 @@ INLINE str bencode_strdup_str(bencode_buffer_t *buf, const char *s) { INLINE str bencode_str_strdup(bencode_buffer_t *buf, const str *s) { str o = *s; o.s = bencode_buffer_alloc(buf, o.len); +#ifdef ASAN_BUILD + if (o.len) +#endif memcpy(o.s, s->s, o.len); return o; }