Pelles C forum
Pelles C => Bug reports => Topic started by: ika on September 10, 2018, 03:34:55 AM
-
If you pass "rt" and "wt" (this is a Microsoft extension) to fopen in Pelles C 8, this does not cause any problems. However in Pelles C 9 it returns NULL. Of course "rt" and "wt" are nonstandard, so that isn't a problem, but errno is never set. So I didn't know what was wrong for a while, because while "strerror(errno)" says "no error", it is an error, which is why it returns NULL. So, I think it would be helpful for an error number and message to be added to strerror about passing in an incorrect mode string.
-
So, more of a feature request really? Yes, seems reasonable (will most likely be EINVAL).
-
Yeah, you're right that I put this in the wrong forum. Thanks for the response!