Commit 7cb00f17 authored by Thomas Jahns's avatar Thomas Jahns 🤸
Browse files

Eliminate unnecessary field size.

parent 9f57fc8a
......@@ -21,7 +21,6 @@ extern char *token;
typedef struct
{
size_t size;
struct dBuffer *fb;
FILE *fp;
int fileID;
......@@ -46,13 +45,12 @@ initBFiledataP(char *filename, size_t bs, int nc, int fileID)
bfp = xmalloc(sizeof (*bfp) + strlen(filename) + 1);
strcpy(bfp->name, filename);
bfp->size = bs;
if (( bfp->fp = fopen ( filename, "w" )) == NULL )
xabort("Failed to open %s", bfp->name);
int fd = fileno(bfp->fp);
ftruncate(fd, (off_t)0);
dbuffer_init ( & ( bfp->fb ), ( size_t )( bfp->size ));
dbuffer_init(&bfp->fb, bs);
bfp->activeCollectors = nc;
......
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