diff options
author | Anders Broman <anders.broman@ericsson.com> | 2009-09-20 08:22:00 +0000 |
---|---|---|
committer | Anders Broman <anders.broman@ericsson.com> | 2009-09-20 08:22:00 +0000 |
commit | 3421576de645a588a87ff5094e7d639945170244 (patch) | |
tree | dab3c9d0477b9e4e204b2199f7818cc05024b62c /gtk/packet_win.c | |
parent | 323e7840227e1d9db2dcd2b46b3e0421fc98fd3f (diff) | |
download | wireshark-3421576de645a588a87ff5094e7d639945170244.tar.gz |
Fix for:
Columns Lazy initialization clobbers cinfo packet buffer. Open a file, goto packet 1000, menu View->Show packet in a new window, the wrong packet is decoded (it's the last displayed in the packet list pane). gtk/packet_win.c:new_window_cb() should call wtap_seek_reread().
svn path=/trunk/; revision=29997
Diffstat (limited to 'gtk/packet_win.c')
-rw-r--r-- | gtk/packet_win.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/gtk/packet_win.c b/gtk/packet_win.c index 7a8a6a8a5b..a77a650ca8 100644 --- a/gtk/packet_win.c +++ b/gtk/packet_win.c @@ -130,6 +130,16 @@ void new_window_cb(GtkWidget *w _U_) *bv_nb_ptr; struct PacketWinData *DataPtr; int i; + int err; + gchar *err_info; + + /* With the new packetlists "lazy columns" it's neccesary to reread the frame */ + if (!wtap_seek_read(cfile.wth, cfile.current_frame->file_off, &cfile.pseudo_header, + cfile.pd, cfile.current_frame->cap_len, &err, &err_info)) { + simple_dialog(ESD_TYPE_ERROR, ESD_BTN_OK, + cf_read_error_message(err, err_info), cfile.filename); + return; + } /* Allocate data structure to represent this window. */ DataPtr = (struct PacketWinData *) g_malloc(sizeof(struct PacketWinData)); |