Hi
I have a struct
and I have created an instance of that
Somewhere in my program I want to write it to file with fputs. The problem is how can I do that?
I get this warning
and after executing the program the content of the file doesn't contain uint32_t numbers. Seems that it is a binary file!!
How can I fix that? thanks
I have a struct
Code:
struct b_entry_t { uint32_t source; uint32_t target; int counter; };
Code:
struct b_entry_t *entry;
Code:
fputs (entry, pFile);
Code:
warning: passing argument 1 of ‘fputs’ from incompatible pointer type /usr/include/stdio.h:682: note: expected ‘const char * __restrict__’ but argument is of type ‘struct b_entry_t *’
How can I fix that? thanks
Comment