projects
/
platform
/
upstream
/
libvorbis.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7fae737
)
Don't crash on successful corrupt file rejection due to being too lazy
author
Monty
<xiphmont@xiph.org>
Tue, 18 Mar 2008 15:43:35 +0000
(15:43 +0000)
committer
Monty
<xiphmont@xiph.org>
Tue, 18 Mar 2008 15:43:35 +0000
(15:43 +0000)
to check return vals.
svn path=/trunk/vorbis/; revision=14599
examples/decoder_example.c
patch
|
blob
|
history
diff --git
a/examples/decoder_example.c
b/examples/decoder_example.c
index
dfb142f
..
2ca4205
100644
(file)
--- a/
examples/decoder_example.c
+++ b/
examples/decoder_example.c
@@
-163,7
+163,11
@@
int main(){
fprintf(stderr,"Corrupt secondary header. Exiting.\n");
exit(1);
}
- vorbis_synthesis_headerin(&vi,&vc,&op);
+ result=vorbis_synthesis_headerin(&vi,&vc,&op);
+ if(result<0){
+ fprintf(stderr,"Corrupt secondary header. Exiting.\n");
+ exit(1);
+ }
i++;
}
}