On Thu, Apr 5, 2012 at 1:51 AM, Willy Tarreau <[email protected]> wrote:
> On Mon, Apr 02, 2012 at 06:57:56PM -0700, Aman Gupta wrote:
>> diff --git a/include/proto/dumpstats.h b/include/proto/dumpstats.h
>> index eb44a36..d328881 100644
>> --- a/include/proto/dumpstats.h
>> +++ b/include/proto/dumpstats.h
>> @@ -55,6 +55,8 @@
>> #define STAT_CLI_O_TAB 8 /* dump tables */
>> #define STAT_CLI_O_CLR 9 /* clear tables */
>>
>> +#define STAT_CLI_EVENTS 8 /* event stream */
>
> This one should apparently be 10 otherwise it conflicts with dump tables
> above.
> Probably that replacing these defines with an enum would fix the issue once
> for
> all BTW.
Oops, missed this in the forward port.
>
>> +/* Callback to release a cli session.
>> + */
>> +static void cli_session_release(struct stream_interface *si)
>> +{
>> + /* remove if registered as event listener */
>> + stats_event_listener_remove(si);
>
> Are you sure you don't need to check if (si->applet.st0 == STAT_CLI_EVENTS)
> here ?
Yep, you're right.
>
> The rest looks good. If you want I can apply the changes above with the patch.
Sounds good, thanks!
Aman
>
> Thanks,
> Willy
>