fopen currently wraps ti_Open. Currently, ti_Open supports r, a, w, r+, a+, and w+.
I am not exactly sure, but I think ti_Open correctly implements rb, ab, and wb since I believe they would behave no different compared to r, a, and w on this platform. However, it only checks if (str[1] == '+'), so rb+ would be treated as r instead of r+
One fix for this is to modify the fileioc logic to check if (str[2] == '+') so rb+ would be interpreted as r+
https://en.cppreference.com/w/c/io/fopen
fopencurrently wrapsti_Open. Currently,ti_Opensupportsr,a,w,r+,a+, andw+.I am not exactly sure, but I think
ti_Opencorrectly implementsrb,ab, andwbsince I believe they would behave no different compared tor,a, andwon this platform. However, it only checksif (str[1] == '+'), sorb+would be treated asrinstead ofr+One fix for this is to modify the fileioc logic to check
if (str[2] == '+')sorb+would be interpreted asr+https://en.cppreference.com/w/c/io/fopen