diff options
author | imoore76 <imoore76@yahoo.com> | 2015-08-05 11:22:42 -0400 |
---|---|---|
committer | imoore76 <imoore76@yahoo.com> | 2015-08-05 11:22:42 -0400 |
commit | cd0f2520d9065c7ce8ced16fb1d1500245689227 (patch) | |
tree | ce31b7428bc71fe785c1cdb90f97cbc58b5b900a /endpoints/lib | |
parent | 2e885ced73e8ab79459e42ed3470fbbdd33c3cad (diff) | |
parent | 021ed6009d780d32b0b60ad06ddccb03fd2a3c30 (diff) | |
download | phpvirtualbox-cd0f2520d9065c7ce8ced16fb1d1500245689227.zip phpvirtualbox-cd0f2520d9065c7ce8ced16fb1d1500245689227.tar.gz phpvirtualbox-cd0f2520d9065c7ce8ced16fb1d1500245689227.tar.bz2 |
Merge pull request #3 from imoore76/develop
5.0-1 2015-08-05
Diffstat (limited to 'endpoints/lib')
-rw-r--r-- | endpoints/lib/vboxconnector.php | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/endpoints/lib/vboxconnector.php b/endpoints/lib/vboxconnector.php index a96746a..c813f78 100644 --- a/endpoints/lib/vboxconnector.php +++ b/endpoints/lib/vboxconnector.php @@ -819,11 +819,6 @@ class vboxconnector { $data['dedupId'] .= '-'. $data['machineId'] .'-' . $data['name']; break; - case 'OnAdditionsStateChanged': - $data['machineId'] = $eventDataObject->machineId; - $data['dedupId'] .= '-'. $data['machineId']; - break; - case 'OnCPUChanged': $data['machineId'] = $data['sourceId']; $data['cpu'] = $eventDataObject->cpu; @@ -1297,12 +1292,12 @@ class vboxconnector { $this->session = $this->websessionManager->getSessionObject($this->vbox->handle); - $machine->lockMachine($this->session->handle, 'Write'); + $machine->lockMachine($this->session->handle, 'Shared'); usort($newGroups,'strnatcasecmp'); if($this->settings->phpVboxGroups) { - $machine->setExtraData(vboxconnector::phpVboxGroupKey, implode(',',$newGroups));
+ $this->session->machine->setExtraData(vboxconnector::phpVboxGroupKey, implode(',', $newGroups));
} else { $this->session->machine->groups = $newGroups; } @@ -1318,6 +1313,13 @@ class vboxconnector { $this->errors[] = $e; $response['errored'] = true; + try { + $this->session->unlockMachine(); + unset($this->session); + } catch (Exception $e) { + // pass + } + continue; } |