summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: f9e6348)
raw | patch | inline | side by side (parent: f9e6348)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 23 Sep 2009 12:50:31 +0000 (12:50 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 23 Sep 2009 12:50:31 +0000 (12:50 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@14332 594d385d-05f5-0310-b6e9-bd551577e9d8
diff --git a/gosa-plugins/opsi/admin/opsiLicenses/class_licenseByProduct.inc b/gosa-plugins/opsi/admin/opsiLicenses/class_licenseByProduct.inc
index 7dfa32139c03e9ed9757a9fa7e0f219009102ce7..b7c2ce5f99e8c3ce68fecd5dedd2a574614d7152 100644 (file)
}else{
$res = $this->si->getLicensesForProduct($this->cn);
- if($this->si->is_error()){
+ if($this->si->is_error() || !$res){
$this->init_successfull = FALSE;
return;
}
diff --git a/gosa-plugins/opsi/admin/opsiLicenses/class_licenseUsageByHost.inc b/gosa-plugins/opsi/admin/opsiLicenses/class_licenseUsageByHost.inc
index 9b38d320ad1d22ca18ff2d14bdd649df1ee02102..a6ba92f37c3bc22cfb72cff4f3f1a009cfa7bc0c 100644 (file)
}else{
$res = $this->si->getLicenseUsage($this->cn);
- if($this->si->is_error()){
+ if($this->si->is_error() || !$res){
$this->init_successfull = FALSE;
return;
}
diff --git a/gosa-plugins/opsi/admin/opsiLicenses/class_opsiLicenseHandler.inc b/gosa-plugins/opsi/admin/opsiLicenses/class_opsiLicenseHandler.inc
index 2fafdae3b0db9ce38aceccfcda736405f7841a33..63e472935c823af1c62319ce93fae364097fee66 100644 (file)
$data['productId'] = htmlentities($productId);
$res = $this->send_data("gosa_opsi_getLicenseInformationForProduct",$this->target,$data,TRUE);
- print_a($res);
-
+ if(isset($res['XML'][0]['ERROR_OPSI_GETLICENSEINFORMATIONFORPRODUCT'])){
+# $this->set_error($res['XML'][0]['ERROR_OPSI_GETLICENSEINFORMATIONFORPRODUCT']);
+ return(FALSE);
+ }
if(isset($res['XML'][0]['ANSWER_OPSI_UNASSIGNALLSOFTWARELICENSESFROMHOST'])){
- return(TRUE);
+ return($res['XML'][0]);
}
return(FALSE);
}