examples : fix tautological-compare warning in stb_vorbis.c [no ci]
This commit applies a fix to address a tautological-compare warning
in stb_vorbis.c.
The motivation for this is that currently the following warning is
generated when compiling the commmand-wasm example:
```console
/Users/danbev/work/ai/whisper-work/examples/stb_vorbis.c:1404:75: warning: pointer comparison always evaluates to false [-Wtautological-compare]
1404 | if (f->stream_start + loc >= f->stream_end || f->stream_start + loc < f->stream_start) {
| ^
1 warning generated.
```
This fix was taken from an open pull request on the stb repository
that addreses this issue:
https://github.com/nothings/stb/pull/1746
This commit is contained in:
parent
93f4dfcbbb
commit
8e3c47d961
|
|
@ -1401,7 +1401,7 @@ static int set_file_offset(stb_vorbis *f, unsigned int loc)
|
|||
#endif
|
||||
f->eof = 0;
|
||||
if (USE_MEMORY(f)) {
|
||||
if (f->stream_start + loc >= f->stream_end || f->stream_start + loc < f->stream_start) {
|
||||
if (loc >= f->stream_len) {
|
||||
f->stream = f->stream_end;
|
||||
f->eof = 1;
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Reference in New Issue