Wireshark-bugs: [Wireshark-bugs] [Bug 954] LDAP and other Statistics filter strings are limited
Date: Thu, 14 Sep 2006 09:17:37 +0000 (GMT)
http://bugs.wireshark.org/bugzilla/show_bug.cgi?id=954


jeff.morriss@xxxxxxxxxxx changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|no LDAP statistics possible |LDAP and other Statistics
                   |                            |filter strings are limited
                   |                            |to 255 chars




------- Comment #2 from jeff.morriss@xxxxxxxxxxx  2006-09-14 09:17 GMT -------
gtk/service_response_time_table.c has this code:

~~~
srt_select_filter_cb(GtkWidget *widget _U_, gpointer callback_data, guint
callback_action)
{
        int action, type, selection;
        srt_stat_table *rst = (srt_stat_table *)callback_data;
        char str[256];
~~~

Similarly, gtk/ldap_stat.c has this code:

~~~
gtk_ldapstat_init(const char *optarg, void *userdata _U_)
{
        ldapstat_t *ldap;
        const char *filter=NULL;
        GtkWidget *label;
        char filter_string[256];
~~~

So it seems that any filter over 255 chars long will be truncated in any
Statistics filter.  Actually, the limit is less than that because all the
statistics modules do:

g_snprintf(filter_string,255,"Filter:%s",filter?filter:"");


All this seems to be in contrast to the main window filter bar which uses code
that takes the string from GTK without imposing a size restriction:

~~~
filter_activate_cb(GtkWidget *w _U_, gpointer data)
{
  const char *s;

  s = gtk_entry_get_text(GTK_ENTRY(data));
~~~

though I could be completely wrong, I'm just poking around in the code. 
Anyway, the problem seems to be the length of the filter and this seems to be
specific to the Statistics items.


-- 
Configure bugmail: http://bugs.wireshark.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.