Closed KArkadiusz closed 11 months ago
Open Group does not directly specify position of file when opened in append mode, documentation only require subsequent
write()
calls to that file to happen at the end-of-file. See: https://pubs.opengroup.org/onlinepubs/9699919799/functions/fopen.html
Checked on Phoenix-rtos-project commit 4e2ac6c.
Upon opening not empty file in "a+" and "ab+" modes, ftell() function shows that the pointer in the file lies at its end, like in "a" mode. Originally, the file pointer should be positioned at the beginning of the file.
ia32 result:
Host result:
Code used for checking:
I suspect it might be the fopen() problem, in test cases ftell() returned expected values in all modes except "a+" and "ab+" so it probably works fine.