I'm running Alpine Linux with MUSL as its standard library within a Docker container based on the official openjdk:16-jdk-alpine3.13 Alpine image. I've used the following minimal test case: ======== #include int main() { FILE* f = fopen("foo", "wb"); fwrite("42", 3, 1, f); fclose(f); f = fopen("foo", "ab"); printf("%d ", (int)ftell(f)); fwrite("42", 3, 1, f); fseek(f, 0, SEEK_END); printf("%d\n", (int)ftell(f)); } ======= On my Alpine/MUSL setup this prints "0 6" while on Ubuntu 22.04 with glibc it prints "3 6" - which I'm assuming is the expected output. So, with MUSL the second fwrite() correctly appends to the existing file, but ftell() nevertheless reports that the initial position within the file after opening it for appending is 0 and not 3. My GCC version is "gcc (Alpine 10.2.1_pre1) 10.2.1 20201203", ldd confirms that the compiled output is linked only against "/lib/ld-musl-x86_64.so.1" and not against glibc. I'm not subscribed to the MUSL mailing list, please CC me on replies. Best Regards, Robert Buchholz