xiaoxiang781216 commented on code in PR #6357: URL: https://github.com/apache/incubator-nuttx/pull/6357#discussion_r889724406
########## libs/libc/stdio/lib_fopen.c: ########## @@ -209,42 +206,39 @@ int lib_mode2oflags(FAR const char *mode) { /* Retain any binary and exclusive mode selections */ - oflags &= (O_BINARY | O_EXCL); + oflags &= FLAG_KEEP; Review Comment: It look like fopen default to the text mode from: https://stackoverflow.com/questions/2174889/whats-the-differences-between-r-and-rb-in-fopen So, I follow your suggestion that: 1. fopen is in the text mode by default 2. Need append "b" to get the binary mode 3. open is in the binary mode by default 4. Need or O_TEXT to get the text mode Please review agian. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org