I've function that opens up a file and than setting it pos
from nvs
at the program start-up. Everything happens after short time and function call end up with error that says [Line : 670] fseek ERROR : Function not implemented
. After short period of time another call works.
I wonder what may cause the problem becouse before I use this specific example with fseek I do multiple fopen/fclose on different files.
FILE *file;
file = fopen("/spiffs/data/log.log", "rb+");
if(file == NULL) return;
if(fseek(file, 30, SEEK_SET) != 0) {
fprintf(stderr, "[Line : %d] fseek ERROR : ", __LINE__);
perror("");
}
File itself is full of data and it length is 10kB
@edit after what @Andrew Henle said in the comment I have looked into what fseek can actualy return. I find out under this link that fseek has no ENOSYS
as return. Which means his point is right but Iam making lots of fopen/fclose/fread before this function call. What conditions has to occur for this error to be returned by f* functions?