From 54c27ff947fd1cb73e6cadf1ef6faa919ad8b4c0 Mon Sep 17 00:00:00 2001 From: Rom Walton Date: Wed, 14 Sep 2011 00:20:17 +0000 Subject: [PATCH] Quick Updates svn path=/trunk/boinc/; revision=24195 --- samples/vboxwrapper/vbox.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/samples/vboxwrapper/vbox.cpp b/samples/vboxwrapper/vbox.cpp index f29b2af227..947671bd7d 100644 --- a/samples/vboxwrapper/vbox.cpp +++ b/samples/vboxwrapper/vbox.cpp @@ -298,6 +298,7 @@ bool VBOX_VM::is_running() { string vmstate; size_t vmstate_location; size_t vmstate_length; + char buf[256]; command = "showvminfo \"" + vm_name + "\" "; command += "--machinereadable "; @@ -309,6 +310,13 @@ bool VBOX_VM::is_running() { vmstate_length = output.find("\"", vmstate_location); vmstate = output.substr(vmstate_location, vmstate_length); + fprintf( + stderr, + "%s Current VM State is '%s'.\n", + boinc_msg_prefix(buf, sizeof(buf)), + vmstate.c_str() + ); + // VirtualBox Documentation suggests that that a VM is running when its // machine state is between MachineState_FirstOnline and MachineState_LastOnline // which as of this writing is 5 and 17.