Hi everybody,
I am using root:
------------------------------------------------------------------
| Welcome to ROOT 6.26/06 |
| (c) 1995-2021, The ROOT Team; conception: R. Brun, F. Rademakers |
| Built for win64 on Jul 28 2022, 18:08:51 |
| From tags/v6-26-06@v6-26-06 |
| With MSVC 19.32.31332.0 |
| Try '.help', '.demo', '.license', '.credits', '.quit'/'.q' |
------------------------------------------------------------------
and I have the following function:
void test() {
FILE *fid = fopen("testfile.txt", "wt");
if (fid != NULL) {
fprintf(fid, "text\n");
//fprintf(fid, " %d \n", 1);
fclose(fid);
} else {
printf("File is not created.\n");
}
}
This function is working properly. But if I remove the comment mark // with intention to write a decimal number in the file (in this case, the decimal number is just 1), root terminates and file is empty. This happens in all case when I am trying to write any variable to the file.
Do you have some idea where is problem?
Vladimir