Huge thanks to our Platinum Members Endace and LiveAction,
and our Silver Member Veeam, for supporting the Wireshark Foundation and project.

Wireshark-dev: [Wireshark-dev] FilterPackets on TCP Stream always filters conversation with ID=

Date: Wed, 15 Jul 2015 13:19:10 +0200 (CEST)

I have to filter single TCP streams out of the open capture file. Therefore I am programmatically applying display-filter "tcp.stream eq TCP_STREAM_ID". The problem I have is that no matter the value of TCP_STREAM_ID, the stream whose id is 0 gets selected.

Please find a snapshot of my code below.

gchar *data_out_filename;
QString follow_filter;
int tmp_fd;

follow_filter=QString("tcp.stream eq 5"); // TCP_STREAM_ID==5

reset_tcp_reassembly();
tmp_fd = create_tempfile(&data_out_filename, "follow");
data_out_file = fdopen(tmp_fd, "w+b");

emit updateFilter(follow_filter, TRUE);

What am I doing wrong? Am I missing anything?