]> jspc29.x-matter.uni-frankfurt.de Git - daqdata.git/commitdiff
Moved writing functions from evt.c to evtuild.c.
authorhades <hades>
Mon, 22 May 2000 08:20:48 +0000 (08:20 +0000)
committerhades <hades>
Mon, 22 May 2000 08:20:48 +0000 (08:20 +0000)
hadaq/Makefile
hadaq/evt.c
hadaq/evt.h
hadaq/evtbuild.c

index 2c559266d8ff551d05dbf625f2bfd836e12714e1..f78f172ad5499f24ea5d937fe77a74b065a164c7 100644 (file)
@@ -135,7 +135,7 @@ agent_xdr.o: agent_xdr.c agent.h
 ctrlctu.o: ctrlctu.c worker.h psxshm.h
 evt.o: evt.c evt.h hadtu.h subevt.h
 evtbuild.o: evtbuild.c worker.h psxshm.h evt.h hadtu.h subevt.h \
- shmtrans.h semaphore.h hadtuqueue.h
+ shmtrans.h semaphore.h hadtuqueue.h ansiTape.h
 hadtu.o: hadtu.c hadtu.h
 hadtuqueue.o: hadtuqueue.c hadtu.h hadtuqueue.h
 hldread.o: hldread.c evt.h hadtu.h subevt.h hldread.h
index 084d30cdd410eb01b99699d0513bf20325d66107..60e67136a75b84d0ed5633a6ef5996ed7af0e0cc 100644 (file)
@@ -1,4 +1,4 @@
-static char rcsId[] = "$Id: evt.c,v 6.6 2000-05-21 21:45:02 hades Exp $";
+static char rcsId[] = "$Id: evt.c,v 6.7 2000-05-22 08:20:48 hades Exp $";
 
 #define _ANSI_C_SOURCE
 #include <stddef.h>
@@ -181,16 +181,6 @@ void deleteEvt(void *my)
        freeMem(my);
 }
 
-int Evt_write(void *my, FILE * file)
-{
-       return fwrite(my, 1, Evt_paddedSize(my), file);
-}
-
-int Evt_writeTape(void *my, AnsiTape *tape)
-{
-       return writeAnsiTape(tape, my, Evt_paddedSize(my));
-}
-
 void *Evt_appendSubEvt(void *my, void *subEvt)
 {
        if (SubEvt_decoding(subEvt) == SubEvtDecoding_SubEvts) {
index 4b59fefcf3cecd910436651432b5b237c0f6551b..f648076e687b1382e4a892a7ed6aa9dd74f97a5e 100644 (file)
@@ -7,7 +7,6 @@
 
 #include "hadtu.h"
 #include "subevt.h"
-#include "ansiTape.h"
 
 #define EVT_MAXSIZE (100 * 1024)
 
@@ -59,8 +58,6 @@ void Evt_setRunNr(void *my, UInt4 runNr);
 
 void *newEvt(UInt4 decoding, UInt4 id, UInt4 runNr);
 void deleteEvt(void *my);
-int Evt_write(void *my, FILE * file);
-int Evt_writeTape(void *my, AnsiTape *tape);
 void *Evt_fget(FILE * file);
 void *Evt_appendSubEvt(void *my, void *subEvt);
 
index 1dbfa64b088a7f8976106337759e84db0ee1227e..d32c5007c89d37c5b01d0934fb7968f2d48cd027 100644 (file)
@@ -1,4 +1,4 @@
-static char rcsId[] = "$Header: /misc/hadesprojects/daq/cvsroot/eventbuilder/hadaq/evtbuild.c,v 6.15 2000-05-21 21:45:02 hades Exp $";
+static char rcsId[] = "$Header: /misc/hadesprojects/daq/cvsroot/eventbuilder/hadaq/evtbuild.c,v 6.16 2000-05-22 08:20:48 hades Exp $";
 
 #define _XOPEN_SOURCE
 #include <unistd.h>
@@ -288,9 +288,9 @@ int main(int argc, char *argv[])
        }
        if (outFile != NULL) {
                if (strcmp(outDev, "file") == 0) {
-                       Evt_write(evt, outFile);
+                       fwrite(evt, 1, Evt_paddedSize(evt), outFile);
                } else if (strcmp(outDev, "tape") == 0) {
-                       Evt_writeTape(evt, outTape);
+                       writeAnsiTape(outTape, evt, Evt_paddedSize(evt));
                }
        }
        deleteEvt(evt);
@@ -354,9 +354,9 @@ int main(int argc, char *argv[])
                if (currNrOfSubEvts == nrOfSubEvts) {
                        if (outFile != NULL) {
                                if (strcmp(outDev, "file") == 0) {
-                                       Evt_write(evt, outFile);
+                                       fwrite(evt, 1, Evt_paddedSize(evt), outFile);
                                } else if (strcmp(outDev, "tape") == 0) {
-                                       Evt_writeTape(evt, outTape);
+                                       writeAnsiTape(outTape, evt, Evt_paddedSize(evt));
                                }
                        }
                        Evt_online(evt);
@@ -375,9 +375,9 @@ int main(int argc, char *argv[])
        }
        if (outFile != NULL) {
                if (strcmp(outDev, "file") == 0) {
-                       Evt_write(evt, outFile);
+                       fwrite(evt, 1, Evt_paddedSize(evt), outFile);
                } else if (strcmp(outDev, "tape") == 0) {
-                       Evt_writeTape(evt, outTape);
+                       writeAnsiTape(outTape, evt, Evt_paddedSize(evt));
                }
        }
        deleteEvt(evt);