Commit 3a509086 authored by 's avatar
Browse files

Changes in read_results


git-svn-id: file:///home/svn/mapi/trunk@544 8d5bb341-7cf1-0310-8cf6-ba355fef3186
parent 8895379d
......@@ -380,7 +380,7 @@ void *process() {
struct stats_t stats[NUMFILTERS] = {{0,0,0,0}};
struct dmapi_results *dres;
mapi_results_t *dres;
char rrd_record[1024], *p;
int i;
double speed;
......@@ -417,11 +417,11 @@ void *process() {
/* read results */
dres = mapi_read_results(filter[i].fd_in, filter[i].fid_in);
bytes_in = *((unsigned long long*)dres->res[0].result);
timestamp_in = dres->res[0].t_produced;
bytes_in = *((unsigned long long*)dres[0].res);
timestamp_in = dres[0].ts;
dres = mapi_read_results(filter[i].fd_out, filter[i].fid_out);
bytes_out = *((unsigned long long*)dres->res[0].result);
timestamp_out = dres->res[0].t_produced;
bytes_out = *((unsigned long long*)dres[0].res);
timestamp_out = dres[0].ts;
// printf(">>>>>>>>>>>>>>>> %llu\n", filter_timestamp[i] - prev_filter_timestamp[i]);
//printf(">>>>>>>>>>>>>>> %s %llu in %llu out bytes\n", filter[i].name , bytes_in, bytes_out);
......@@ -448,9 +448,9 @@ void *process() {
if((times % 5) == 1 ) { //&& ((i == 0) || filter[i].type == F_TRACKER)) {
dres=mapi_read_results(filter[i].fd_in,filter[i].top_in);
cnt = ((unsigned int*)dres->res[0].result);
timestamp_in = dres->res[0].t_produced;
result_time = dres->res[0].t_produced;
cnt = ((unsigned int*)dres[0].res);
timestamp_in = dres[0].ts;
result_time = dres[0].ts;
tmp=(struct topx_result *)(cnt+1);
......@@ -475,9 +475,9 @@ void *process() {
dres=mapi_read_results(filter[i].fd_out,filter[i].top_out);
result_time = dres->res[0].t_produced;
cnt = ((unsigned int*)dres->res[0].result);
timestamp_out = dres->res[0].t_produced;
result_time = dres[0].ts;
cnt = ((unsigned int*)dres[0].res);
timestamp_out = dres[0].ts;
tmp=(struct topx_result *)(cnt+1);
......
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