Commit 676a646c authored by Arne Øslebø's avatar Arne Øslebø
Browse files

fixed bug in return value

git-svn-id: file:///home/svn/mapi/trunk@357 8d5bb341-7cf1-0310-8cf6-ba355fef3186
parent 21d9f3a5
...@@ -56,7 +56,7 @@ static int to_tcpdump_init(mapidflib_function_instance_t *instance, ...@@ -56,7 +56,7 @@ static int to_tcpdump_init(mapidflib_function_instance_t *instance,
i->pkts=0; i->pkts=0;
instance->internal_data=i; instance->internal_data=i;
res=instance->result.data; res=instance->result.data;
*res=1; *res=11;
//Write PCAP header //Write PCAP header
head.magic=2712847316U; head.magic=2712847316U;
...@@ -83,6 +83,8 @@ static int to_tcpdump_process(mapidflib_function_instance_t *instance,MAPI_UNUSE ...@@ -83,6 +83,8 @@ static int to_tcpdump_process(mapidflib_function_instance_t *instance,MAPI_UNUSE
return 1; return 1;
} }
printf("Res 1\n");
phdr.caplen=pkthdr->caplen; phdr.caplen=pkthdr->caplen;
phdr.len=pkthdr->wlen; phdr.len=pkthdr->wlen;
phdr.ts.tv_sec=pkthdr->ts >> 32; phdr.ts.tv_sec=pkthdr->ts >> 32;
...@@ -110,7 +112,7 @@ static mapidflib_function_def_t finfo={ ...@@ -110,7 +112,7 @@ static mapidflib_function_def_t finfo={
"iwl", "iwl",
MAPI_DEVICE_ALL, MAPI_DEVICE_ALL,
MAPIRES_SHM, MAPIRES_SHM,
sizeof(char), //shm size sizeof(int), //shm size
0, //modifies_pkts 0, //modifies_pkts
0, //filters packets 0, //filters packets
MAPIOPT_NONE, //Optimization MAPIOPT_NONE, //Optimization
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment