You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficserver.apache.org by "Leif Hedstrom (JIRA)" <ji...@apache.org> on 2014/12/17 21:38:13 UTC

[jira] [Created] (TS-3244) stats_over_http plugin does not get the optional path argument properly

Leif Hedstrom created TS-3244:
---------------------------------

             Summary: stats_over_http plugin does not get the optional path argument properly
                 Key: TS-3244
                 URL: https://issues.apache.org/jira/browse/TS-3244
             Project: Traffic Server
          Issue Type: Bug
          Components: Plugins
            Reporter: Leif Hedstrom


To override the default path for stats_over_http.so with your own, you should add this to plugin.config:

{code}
stats_over_http.so /my_stats_path
{code}

This no longer works. Patch would be

{code}
diff --git a/plugins/stats_over_http/stats_over_http.c b/plugins/stats_over_http/stats_over_http.c
index 720a7e7..9c4f8bf 100644
--- a/plugins/stats_over_http/stats_over_http.c
+++ b/plugins/stats_over_http/stats_over_http.c
@@ -312,8 +312,8 @@ init:
   argc -= optind;
   argv += optind;
 
-  if (argc > 1) {
-    url_path = TSstrdup(argv[1] + ('/' == argv[1][0] ? 1 : 0)); /* Skip leading / */
+  if (argc > 0) {
+    url_path = TSstrdup(argv[0] + ('/' == argv[0][0] ? 1 : 0)); /* Skip leading / */
   }
   url_path_len = strlen(url_path);
 {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)