Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(553)

Unified Diff: webrtc/modules/audio_coding/codecs/g711/test/testG711.cc

Issue 1174813003: Prepare to convert various types to size_t. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc@master
Patch Set: Review comments + resync Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/audio_coding/codecs/g711/test/testG711.cc
diff --git a/webrtc/modules/audio_coding/codecs/g711/test/testG711.cc b/webrtc/modules/audio_coding/codecs/g711/test/testG711.cc
index e891810ca957d3ea82b641cec74d926bf7a546e3..9511df7915a16efa24d58eb96d4f307bcf8642d5 100644
--- a/webrtc/modules/audio_coding/codecs/g711/test/testG711.cc
+++ b/webrtc/modules/audio_coding/codecs/g711/test/testG711.cc
@@ -86,6 +86,10 @@ int main(int argc, char* argv[]) {
printf("G.711 version: %s\n\n", versionNumber);
/* Get frame length */
framelength = atoi(argv[1]);
+ if (framelength < 0) {
+ printf(" G.711: Invalid framelength %d.\n", framelength);
+ exit(1);
+ }
/* Get compression law */
strcpy(law, argv[2]);

Powered by Google App Engine
This is Rietveld 408576698