From c87d22d53faead9c0ce52246073b9082055d3a3f Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Fri, 1 Oct 2021 08:21:05 -0500 Subject: [PATCH] fix: coverity regressions reported on 2021-10-01 (#1869) leaks introduced by 3fd5c81a --- libtransmission/announcer-udp.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libtransmission/announcer-udp.cc b/libtransmission/announcer-udp.cc index 447efae52..a24059b26 100644 --- a/libtransmission/announcer-udp.cc +++ b/libtransmission/announcer-udp.cc @@ -195,7 +195,7 @@ static struct tau_scrape_request* tau_scrape_request_new( req->transaction_id = transaction_id; req->callback = callback; req->user_data = user_data; - req->response.url = tr_strdup(in->url); + req->response.url = in->url; req->response.row_count = in->info_hash_count; req->payload.assign(payload_begin, payload_end); @@ -229,7 +229,7 @@ static void tau_scrape_request_fail(struct tau_scrape_request* request, bool did { request->response.did_connect = did_connect; request->response.did_timeout = did_timeout; - request->response.errmsg = tr_strdup(errmsg); + request->response.errmsg = errmsg; tau_scrape_request_finished(request); }