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

Side by Side 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 79
80 } 80 }
81 81
82 /* Get version and print */ 82 /* Get version and print */
83 WebRtcG711_Version(versionNumber, 40); 83 WebRtcG711_Version(versionNumber, 40);
84 84
85 printf("-----------------------------------\n"); 85 printf("-----------------------------------\n");
86 printf("G.711 version: %s\n\n", versionNumber); 86 printf("G.711 version: %s\n\n", versionNumber);
87 /* Get frame length */ 87 /* Get frame length */
88 framelength = atoi(argv[1]); 88 framelength = atoi(argv[1]);
89 if (framelength < 0) {
90 printf(" G.711: Invalid framelength %d.\n", framelength);
91 exit(1);
92 }
89 93
90 /* Get compression law */ 94 /* Get compression law */
91 strcpy(law, argv[2]); 95 strcpy(law, argv[2]);
92 96
93 /* Get Input and Output files */ 97 /* Get Input and Output files */
94 sscanf(argv[3], "%s", inname); 98 sscanf(argv[3], "%s", inname);
95 sscanf(argv[4], "%s", outname); 99 sscanf(argv[4], "%s", outname);
96 if (argc == 6) { 100 if (argc == 6) {
97 sscanf(argv[5], "%s", bitname); 101 sscanf(argv[5], "%s", bitname);
98 if ((bitp = fopen(bitname, "wb")) == NULL) { 102 if ((bitp = fopen(bitname, "wb")) == NULL) {
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 printf("Time to run G.711: %.2f s (%.2f %% of realtime)\n\n", 174 printf("Time to run G.711: %.2f s (%.2f %% of realtime)\n\n",
171 runtime, 175 runtime,
172 (100 * runtime / length_file)); 176 (100 * runtime / length_file));
173 printf("---------------------END----------------------\n"); 177 printf("---------------------END----------------------\n");
174 178
175 fclose(inp); 179 fclose(inp);
176 fclose(outp); 180 fclose(outp);
177 181
178 return 0; 182 return 0;
179 } 183 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698