]> jspc29.x-matter.uni-frankfurt.de Git - daqdata.git/commitdiff
Added portNr to shared mem by worker. Sergey.
authorhadaq <hadaq>
Thu, 19 Aug 2010 13:31:43 +0000 (13:31 +0000)
committerhadaq <hadaq>
Thu, 19 Aug 2010 13:31:43 +0000 (13:31 +0000)
hadaq/netmem.c

index 6d8f150c9edb92f111febf64cb613fbf2f4a5c0a..52f8d216bf327c38c3a11ac824362e2342c70d87 100644 (file)
@@ -1,4 +1,4 @@
-static char *rcsId = "$Header: /misc/hadesprojects/daq/cvsroot/eventbuilder/hadaq/netmem.c,v 6.45 2010-08-16 14:42:21 hadaq Exp $";
+static char *rcsId = "$Header: /misc/hadesprojects/daq/cvsroot/eventbuilder/hadaq/netmem.c,v 6.46 2010-08-19 13:31:43 hadaq Exp $";
 
 #define _POSIX_C_SOURCE 199309L
 #define SYSLOG_NAMES
@@ -54,6 +54,7 @@ typedef struct TheStatsS {
        unsigned long *netmemBuff[MAXINPATH];
        unsigned long *nrOfMsgs;
        unsigned long *recvBytesRate[MAXINPATH];
+       unsigned long *portNr[MAXINPATH];
 } TheStats;
 
 static jmp_buf terminateJmp;
@@ -629,6 +630,10 @@ int main(int argc, char *argv[])
 
                sprintf(buf, "bytesReceivedRate%d", i);
                theStats->recvBytesRate[i] = Worker_addStatistic(worker, buf);
+
+               sprintf(buf, "portNr%d", i);
+               theStats->portNr[i] = Worker_addStatistic(worker, buf);
+               (*theStats->portNr[i]) = theArgs->portNr[i];
        }
 
        theStats->nrOfMsgs = Worker_addStatistic(worker, "nrOfMsgs");