trafficserver-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a..@apache.org
Subject [trafficserver] branch master updated: TS-4976: Regularize plugins - passthru
Date Thu, 23 Mar 2017 00:57:37 GMT
This is an automated email from the ASF dual-hosted git repository.

amc 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  c2068e3   TS-4976: Regularize plugins - passthru
c2068e3 is described below

commit c2068e3c6162863989a4555d214bb7fc67dbdc56
Author: Alan M. Carroll <amc@apache.org>
AuthorDate: Wed Mar 22 19:55:41 2017 -0500

    TS-4976: Regularize plugins - passthru
---
 example/passthru/passthru.cc | 14 ++++----------
 1 file changed, 4 insertions(+), 10 deletions(-)

diff --git a/example/passthru/passthru.cc b/example/passthru/passthru.cc
index 426fc16..0b13e8a 100644
--- a/example/passthru/passthru.cc
+++ b/example/passthru/passthru.cc
@@ -267,7 +267,7 @@ PassthruSessionEvent(TSCont cont, TSEvent event, void *edata)
     return TS_EVENT_NONE;
   }
 
-  TSError("%s: unexpected event %s (%d) edata=%p", PLUGIN_NAME, TSHttpEventNameLookup(event),
event, arg.edata);
+  TSError("[%s] unexpected event %s (%d) edata=%p", PLUGIN_NAME, TSHttpEventNameLookup(event),
event, arg.edata);
 
   return TS_EVENT_ERROR;
 }
@@ -298,13 +298,13 @@ PassthruListen()
   TSCont cont                 = nullptr;
 
   if (TSMgmtStringGet("config.plugin.passthru.server_ports", &ports) == TS_ERROR) {
-    TSError("%s: missing config.plugin.passthru.server_ports configuration", PLUGIN_NAME);
+    TSError("[%s] missing config.plugin.passthru.server_ports configuration", PLUGIN_NAME);
     return TS_ERROR;
   }
 
   descriptor = TSPortDescriptorParse(ports);
   if (descriptor == nullptr) {
-    TSError("%s: failed to parse config.plugin.passthru.server_ports", PLUGIN_NAME);
+    TSError("[%s] failed to parse config.plugin.passthru.server_ports", PLUGIN_NAME);
     TSfree(ports);
     return TS_ERROR;
   }
@@ -319,13 +319,7 @@ PassthruListen()
 void
 TSPluginInit(int /* argc */, const char * /* argv */ [])
 {
-  // clang-format off
-    TSPluginRegistrationInfo info = {
-        const_cast<char*>(PLUGIN_NAME),
-        const_cast<char*>("Apache Software Foundation"),
-        const_cast<char*>("dev@trafficserver.apache.org"),
-    };
-  // clang-format on
+  TSPluginRegistrationInfo info = {PLUGIN_NAME, "Apache Software Foundation", "dev@trafficserver.apache.org"};
 
   TSReturnCode status;
 

-- 
To stop receiving notification emails like this one, please contact
['"commits@trafficserver.apache.org" <commits@trafficserver.apache.org>'].

Mime
View raw message