[ 
https://issues.apache.org/jira/browse/TS-3244?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Leif Hedstrom updated TS-3244:
------------------------------
    Fix Version/s: 5.3.0
                   5.2.0

> 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
>             Fix For: 5.2.0, 5.3.0
>
>         Attachments: stats_getopt.diff
>
>
> 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)

Reply via email to