[vbox-dev] v5.0.14 copy files to guest bug
Matthew Donovan
mdonovan at atcorp.com
Thu Mar 3 17:41:18 UTC 2016
I was looking at the file copy problem in version 5.0.14. The immediate
problem is that when invoking the vbox_cat process, the argv array is not
created correctly. Specifically, the program name is omitted and argv[0]
is the first argument to the command. I say "immediate problem" because
the arguments you give to VBoxManage are not handled correctly e.g., the
--target-directory argument is treated as the destination file path, not
just directory.
This is the first time I've submitted a patch, please let me know if it is
not in the correct format or there are problems with it.
Thanks
-Matthew
--- a/src/VBox/Main/src-client/GuestSessionImplTasks.cpp 2016-01-19
11:45:52.000000000 -0500
+++ b/src/VBox/Main/src-client/GuestSessionImplTasks.cpp 2016-03-01
12:50:59.053201400 -0500
@@ -315,6 +315,7 @@
procInfo.mFlags = ProcessCreateFlag_Hidden;
/* Set arguments.*/
+ procInfo.mArguments.push_back(Utf8Str(VBOXSERVICE_TOOL_CAT));
procInfo.mArguments.push_back(Utf8StrFmt("--output=%s",
mDest.c_str())); /** @todo Do we need path conversion? */
/* Startup process. */
@@ -643,6 +644,7 @@
procInfo.mFlags = ProcessCreateFlag_Hidden |
ProcessCreateFlag_WaitForStdOut;
/* Set arguments.*/
+
procInfo.mArguments.push_back(Utf8Str(VBOXSERVICE_TOOL_CAT));
procInfo.mArguments.push_back(mSource); /* Which file to
output? */
/* Startup process. */
More information about the vbox-dev
mailing list