Skip to content

Commit

Permalink
try again to fix print specs
Browse files Browse the repository at this point in the history
  • Loading branch information
carltimmer committed Sep 20, 2024
1 parent 41236fb commit 6a3c273
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions src/libsrc/evio.c
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@
#include <sys/mman.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <inttypes.h>
#include "evio.h"


Expand Down Expand Up @@ -3169,7 +3170,7 @@ if (debug) printf("evOpen: append, opened file %s\n", filename);
freeEVFILE(a);
return(S_EVFILE_BADFILE);
}
if (debug) printf("evOpen: append, read in %ld bytes\n", nBytes);
if (debug) printf("evOpen: append, read in %" PRId64 " bytes\n", nBytes);
}
else {
err = evGenerateBaseFileName(filename, &baseName, &specifierCount);
Expand Down Expand Up @@ -5743,7 +5744,7 @@ static int evWriteImpl(int handle, const uint32_t *buffer, int useMutex)
uint32_t bytesCommittedToWrite = a->bytesToDataBuf + 4*(a->blkEvCount);

if (debug && a->splitting) {
printf("evWrite: splitting, bytesToFile = %lu, event bytes = %u, bytesToBuf = %u, split = %lu\n",
printf("evWrite: splitting, bytesToFile = %" PRIu64 ", event bytes = %u, bytesToBuf = %u, split = %" PRIu64 "\n",
a->bytesToFile, bytesToWrite, a->bytesToBuf, a->split);
printf("evWrite: blockNum = %u, (blkNum == 2) = %d, eventsToBuf (%u) <=? common blk cnt (%u)\n",
a->blknum, (a->blknum == 2), a->eventsToBuf, a->commonBlkCount);
Expand Down Expand Up @@ -5780,10 +5781,10 @@ printf("evWrite: too many events in block, already have %u\n", a->blkEvCount );
}

if (debug) {
printf("evWrite: splitting = %s: total size = %lu >? split = %lu\n",
printf("evWrite: splitting = %s: total size = %" PRIu64 " >? split = %" PRIu64 "\n",
(totalSize > a->split ? "True" : "False"), totalSize, a->split);

printf("evWrite: total size components: bytesToFile = %lu, bytesToBuf = %u, ev bytes = %u, data bytes = %u\n",
printf("evWrite: total size components: bytesToFile = %" PRIu64 ", bytesToBuf = %u, ev bytes = %u, data bytes = %u\n",
a->bytesToFile, a->bytesToBuf, bytesToWrite, a->bytesToDataBuf);
}

Expand Down Expand Up @@ -5930,7 +5931,7 @@ if (debug) {
printf(" internal buffer cnt = %u\n", a->eventsToBuf);
printf(" current block cnt (dict) = %u\n", a->blkEvCount);
printf(" bytes-to-buf = %u\n", a->bytesToBuf);
printf(" bytes-to-file = %lu\n", a->bytesToFile);
printf(" bytes-to-file = %" PRIu64 "\n", a->bytesToFile);
printf(" bytes-to-databuf = %u\n", a->bytesToDataBuf);
printf(" block # = %u\n", a->blknum);
}
Expand Down Expand Up @@ -6204,7 +6205,7 @@ if (debug) printf(" flushToDestination: write %u as record count to file head
printf(" internal buffer cnt (dict) = %u\n", a->eventsToBuf);
printf(" current block cnt (dict) = %u\n", a->blkEvCount);
printf(" bytes-written = %u\n", bytesToWrite);
printf(" bytes-to-file = %lu\n", a->bytesToFile);
printf(" bytes-to-file = %" PRIu64 "\n", a->bytesToFile);
printf(" block # = %u\n", a->blknum);
}

Expand Down Expand Up @@ -6987,13 +6988,13 @@ if (debug) printf("evIoctl: increasing internal buffer size to %u words\n", buff
/* Smallest possible evio format file = 10 32-bit ints.
* Must also be bigger than a single buffer? */
if (splitSize < 4*10) {
if (debug) printf("evIoctl: split file size is too small! (%lu bytes), must be min 40\n", splitSize);
if (debug) printf("evIoctl: split file size is too small! (%" PRIu64 " bytes), must be min 40\n", splitSize);
handleUnlock(handle);
return(S_EVFILE_BADSIZEREQ);
}

a->split = splitSize;
if (debug) printf("evIoctl: split file at %lu (0x%lx) bytes\n", splitSize, splitSize);
if (debug) printf("evIoctl: split file at %" PRIu64 " (0x%" PRIx64 ") bytes\n", splitSize, splitSize);
break;

/************************************************/
Expand Down

0 comments on commit 6a3c273

Please sign in to comment.