Palacios Public Git Repository

To checkout Palacios execute

  git clone http://v3vee.org/palacios/palacios.web/palacios.git
This will give you the master branch. You probably want the devel branch or one of the release branches. To switch to the devel branch, simply execute
  cd palacios
  git checkout --track -b devel origin/devel
The other branches are similar.


HVM capability enhancement: asynchronous upcalls to ROS userspace
[palacios.git] / linux_usr / v3_stream.c
index 8a3733a..f3157d7 100644 (file)
@@ -96,6 +96,8 @@ int process_escapes(char in)
        found_esc = 1;
     return 1;
   }
+
+  return 0;
 }
 
 int pump(int in, int out)
@@ -182,7 +184,7 @@ int main(int argc, char* argv[])
   char stream[STREAM_NAME_LEN];
   int argstart;
   
-  if (argc < 2) {
+  if (argc < 3) {
     usage(argv[0]);
     exit(0);
   }
@@ -190,7 +192,7 @@ int main(int argc, char* argv[])
   if (!strcasecmp(argv[1],"-i")) { 
     interactive=1;
     argstart=2;
-    if (argc < 3) {
+    if (argc < 4) {
         usage(argv[0]);
         exit(0);
     } 
@@ -207,7 +209,7 @@ int main(int argc, char* argv[])
     exit(-1);
   }
 
-  memcpy(stream, argv[argstart+1], strlen(argv[argstart+1]));
+  memcpy(stream, argv[argstart+1], strlen(argv[argstart+1])+1);
   
   vm_fd = open(vm_dev, O_RDONLY);