(bug 1404) Bound user input in tutorial third.cc program
authorTom Henderson <tomh@tomh.org>
Fri, 04 May 2012 16:32:59 -0700
changeset 7879 0e14523a87fd
parent 7878 715b1f392880
child 7880 f5c22d8411e6
(bug 1404) Bound user input in tutorial third.cc program
examples/tutorial/third.cc
--- a/examples/tutorial/third.cc	Fri May 04 16:16:41 2012 -0700
+++ b/examples/tutorial/third.cc	Fri May 04 16:32:59 2012 -0700
@@ -52,6 +52,13 @@
 
   cmd.Parse (argc,argv);
 
+  if (nWifi > 18)
+    {
+      std::cout << "Number of wifi nodes " << nWifi << 
+                   " specified exceeds the mobility bounding box" << std::endl;
+      exit (1);
+    }
+
   if (verbose)
     {
       LogComponentEnable ("UdpEchoClientApplication", LOG_LEVEL_INFO);