Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

libpcap double reads pcap data from file under Ubuntu 16.04 #62

Closed
jelu opened this issue Jun 6, 2016 · 0 comments
Closed

libpcap double reads pcap data from file under Ubuntu 16.04 #62

jelu opened this issue Jun 6, 2016 · 0 comments
Assignees
Labels
Milestone

Comments

@jelu
Copy link
Member

jelu commented Jun 6, 2016

Weird problem, libpcap seems to reset the file handle after clone() and then rereads all data. Need to report upstreams.

Strace diff output:

 open("./1458044657.pcap.dist", O_RDONLY) = 3
 fstat(3, {st_mode=S_IFREG|0664, st_size=1020, ...}) = 0
 read(3, "\324\303\262\241\2\0\4\0\0\0\0\0\0\0\0\0\377\377\0\0\1\0\0\0\357\376\347V \354\3\0"..., 4096) = 1020
-clone(child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0x7f76ad71aa10) = 7448
...
-lseek(3, -996, SEEK_CUR <unfinished ...>
...
-read(3, "\357\376\347V \354\3\0I\0\0\0I\0\0\0>1\220\201\223\263\2B\254\21\0\20\10\0E\0"..., 4096) = 996
...
 read(3, "", 4096)                 = 0
@jelu jelu added the bug label Jun 6, 2016
@jelu jelu added this to the v2.1.0 milestone Jun 6, 2016
@jelu jelu self-assigned this Jun 6, 2016
@jelu jelu closed this as completed in a28f5d4 Jun 7, 2016
jelu added a commit that referenced this issue Jun 7, 2016
Fix #62: Do not go into daemon mode if reading offline files
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant