You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by dm...@apache.org on 2024/04/15 12:16:06 UTC

(trafficserver) branch master updated: CID 1374999: plugin stale_response, delete pointer on early exit. (#11248)

This is an automated email from the ASF dual-hosted git repository.

dmeden pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficserver.git


The following commit(s) were added to refs/heads/master by this push:
     new 10e01239e9 CID 1374999: plugin stale_response, delete pointer on early exit. (#11248)
10e01239e9 is described below

commit 10e01239e9c6ef5b969de65b9256d55b83fb497f
Author: Damian Meden <dm...@apache.org>
AuthorDate: Mon Apr 15 14:16:00 2024 +0200

    CID 1374999: plugin stale_response, delete pointer on early exit. (#11248)
---
 plugins/experimental/stale_response/stale_response.cc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/plugins/experimental/stale_response/stale_response.cc b/plugins/experimental/stale_response/stale_response.cc
index a4c81649d4..bb1d1dfff6 100644
--- a/plugins/experimental/stale_response/stale_response.cc
+++ b/plugins/experimental/stale_response/stale_response.cc
@@ -1068,6 +1068,7 @@ TSPluginInit(int argc, const char *argv[])
   // proxy.config.http.insert_age_in_response
   if (TS_SUCCESS != TSUserArgIndexReserve(TS_USER_ARGS_TXN, PLUGIN_TAG, "reserve state info slot", &(plugin_config->txn_slot))) {
     TSError("stale_response [%s] failed to user argument data. Plugin registration failed.", PLUGIN_TAG);
+    delete plugin_config;
     return;
   }
   TSCont main_contp = TSContCreate(global_request_header_hook, nullptr);