diff --git a/checkin_notes b/checkin_notes index a20f432752..f5a2c8d056 100644 --- a/checkin_notes +++ b/checkin_notes @@ -180,3 +180,12 @@ Rom 4 Jan 2012 samples/vboxwrapper/ vbox.cpp + +Rom 4 Jan 2012 + - VBOX: Fix a crash bug if multiple virtual VICs are defined for a VM. + I'm not sure what the heck happened. It probably has something to + do with my \r removal code on Windows. Bugs hidden by other bugs + I suppose. + + samples/vboxwrapper/ + vbox.cpp diff --git a/samples/vboxwrapper/vbox.cpp b/samples/vboxwrapper/vbox.cpp index e7cafc5783..ac63d2e7a6 100644 --- a/samples/vboxwrapper/vbox.cpp +++ b/samples/vboxwrapper/vbox.cpp @@ -1279,7 +1279,7 @@ int VBOX_VM::get_network_bytes_received(double& received) { counter_end = output.find("\"", counter_start); counter_value = output.substr(counter_start, counter_end - counter_start); received += atof(counter_value.c_str()); - counter_start = output.find("\n", counter_start); + counter_start = output.find("c=\"", counter_start); } return 0; @@ -1315,7 +1315,7 @@ int VBOX_VM::get_network_bytes_sent(double& sent) { counter_end = output.find("\"", counter_start); counter_value = output.substr(counter_start, counter_end - counter_start); sent += atof(counter_value.c_str()); - counter_start = output.find("\n", counter_start); + counter_start = output.find("c=\"", counter_start); } return 0; }