mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-02 03:00:34 +03:00
F_SETFL was replacing the whole flags word, so fcntl(fd, F_SETFL, O_APPEND) made F_GETFL report O_RDONLY|O_APPEND. Keep O_ACCMODE and apply only POSIX status flags. Co-authored-by: Cursor <cursoragent@cursor.com>