Posts by Kollins Lima • 133 points
3 posts
-
1
votes2
answers495
viewsA: Problems with fwrite in binary file
I found a solution to the problem. Using the r+b mode the algorithm works (I was using a+b to create a file if it didn’t exist, but for some reason this mode isn’t working in my application).
-
2
votes2
answers495
viewsQ: Problems with fwrite in binary file
I am trying to write and read an integer in binary file with the following code: #include<stdio.h> #include<stdlib.h> #include<string.h> typedef struct{ int free_slot; }header;…
-
10
votes3
answers42472
viewsQ: Error Segmentation fault (core dumped)
I’m getting the following error message in my code: Segmentation fault (core dumped) Another thing is, when I performed the same function operation preenche in the main, using ficha.name in place of…