Commit Graph

2 Commits

Author SHA1 Message Date
Richard Lescak
63f4fa04b2 rebase to version 3.0.5 2022-07-29 20:10:46 +02:00
Timm Bäder
a93b3655b0 Fix str_open() in a different way
The original patch tried to fix it by not assigning anything to
open_mode. That only works if the compiler is able to deduce that bug()
will abort the process however (or just not warn about the uninitialized
use of open_mode). clang does warn about open_mode being used
uninitialized in this function.

Solve this by rewriting the function to simply only consider one case,
the mode == kVSFSysStrOpenReadOnly one. Otherwise, don't call
vsf_sysutil_open_file() and just return -1 after calling bug().
2020-11-17 10:16:57 +01:00