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

Side by Side Diff: media/cast/test/utility/udp_proxy_main.cc

Issue 248083005: Reland: [Cast] Consolidate plethora of GYP files into cast.gyp and cast_testing.gypi. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixes to problems exposed by r265481. Created 6 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « media/cast/test/utility/generate_timecode_audio.cc ('k') | media/cast/test/utility/utility.gyp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <cstdio> 5 #include <cstdio>
6 #include <cstdlib> 6 #include <cstdlib>
7 #include <string> 7 #include <string>
8 8
9 #include "base/at_exit.h" 9 #include "base/at_exit.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
11 #include "base/command_line.h" 11 #include "base/command_line.h"
12 #include "base/logging.h" 12 #include "base/logging.h"
13 #include "base/message_loop/message_loop.h"
13 #include "media/cast/test/utility/udp_proxy.h" 14 #include "media/cast/test/utility/udp_proxy.h"
14 15
15 int main(int argc, char** argv) { 16 int main(int argc, char** argv) {
16 if (argc < 5) { 17 if (argc < 5) {
17 fprintf(stderr, 18 fprintf(stderr,
18 "Usage: udp_proxy <localport> <remotehost> <remoteport> <type>\n" 19 "Usage: udp_proxy <localport> <remotehost> <remoteport> <type>\n"
19 "Where type is one of: perfect, wifi, evil\n"); 20 "Where type is one of: perfect, wifi, evil\n");
20 exit(1); 21 exit(1);
21 } 22 }
22 23
(...skipping 26 matching lines...) Expand all
49 exit(1); 50 exit(1);
50 } 51 }
51 52
52 printf("Press Ctrl-C when done.\n"); 53 printf("Press Ctrl-C when done.\n");
53 scoped_ptr<media::cast::test::UDPProxy> proxy( 54 scoped_ptr<media::cast::test::UDPProxy> proxy(
54 media::cast::test::UDPProxy::Create(local_endpoint, 55 media::cast::test::UDPProxy::Create(local_endpoint,
55 remote_endpoint, 56 remote_endpoint,
56 in_pipe.Pass(), 57 in_pipe.Pass(),
57 out_pipe.Pass(), 58 out_pipe.Pass(),
58 NULL)); 59 NULL));
59 while (true) { 60 base::MessageLoop().Run(); // Run forever.
60 sleep(1000);
61 }
62 return 1; 61 return 1;
63 } 62 }
OLDNEW
« no previous file with comments | « media/cast/test/utility/generate_timecode_audio.cc ('k') | media/cast/test/utility/utility.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698