Bug in GTK CList gtk_clist_append?



I am so completely stumped.  This particular area of code works if there
are only 2 entries in the directory.  If there are more than 2 it does
this:

Anyone want to attempt telling me what this means?  =)

#0  0x401c61ff in g_strdup (str=0x1 <Address 0x1 out of bounds>)
    at gstrfuncs.c:56
#1  0x4008634f in set_cell_contents (clist=0x80abc28, clist_row=0x80c6bd8, 
    column=1, type=GTK_CELL_TEXT, text=0x1 <Address 0x1 out of bounds>, 
    spacing=0 '\000', pixmap=0x0, mask=0x0) at gtkclist.c:2475
#2  0x40086a49 in real_insert_row (clist=0x80abc28, row=2,
    text=0xbfffebc8) at gtkclist.c:2646
#3  0x4008675e in gtk_clist_append (clist=0x80abc28, text=0xbfffebc8)
    at gtkclist.c:2584
#4  0x8054d08 in add_search_entry_activate (editable=0x80abf58, 
    user_data=0x80abf58) at ./db/callbacks.c:281


(callbacks.c:  linbe 281 is the line row = gtk...)

  i = scandir (path[0], &filelist, add_select, alphasort);

  if (i < 0)
    printf ("scandir error\n");
  else {
    gtk_entry_set_text (GTK_ENTRY (user_data), path[0]);
    for (j = 0; j < i; j++) {
      row = gtk_clist_append (GTK_CLIST (add_file_list), path);
      gtk_clist_set_text (GTK_CLIST (add_file_list), row, 1,
                           filelist[j]->d_name);
    }
  }


Thanks to all who may have an answer for me... or possibly a solution?

Leeman

-- 

Leeman Strout

Systems Engineer
ETC Support





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]