Github user sudheerv commented on a diff in the pull request: https://github.com/apache/trafficserver/pull/442#discussion_r51277409 --- Diff: lib/atscppapi/src/Transaction.cc --- @@ -433,14 +411,12 @@ class initializeHandles initializeHandles(GetterFunction getter) : getter_(getter) {} bool operator()(TSHttpTxn txn, TSMBuffer &hdr_buf, TSMLoc &hdr_loc, const char *handles_name) { - if (!hdr_buf && !hdr_loc) { - if (getter_(txn, &hdr_buf, &hdr_loc) == TS_SUCCESS) { - return true; - } else { - LOG_ERROR("Could not get %s", handles_name); - } + hdr_buf = NULL; + hdr_loc = NULL; + if (getter_(txn, &hdr_buf, &hdr_loc) == TS_SUCCESS) { + return true; } else { - LOG_ERROR("%s already initialized", handles_name); + LOG_ERROR("Could not get %s", handles_name); --- End diff -- The handles inside the Request and Response objects need to be reset here as well, otherwise, plugins may reference invalid handles via those objects.
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---