Sophie

Sophie

distrib > Mageia > 8 > i586 > media > core-updates_testing-src > by-pkgid > 59d4ced5c428aea159c9d7c0aae9af17 > files > 2

phppgadmin-7.13.0-1.1.mga8.src.rpm

diff -r 071af26103e4 all_db.php
--- a/all_db.php	Thu Mar 11 18:40:52 2021 +0100
+++ b/all_db.php	Thu Mar 11 18:44:57 2021 +0100
@@ -199,7 +199,7 @@
 		echo "\t\t<td class=\"data1\">\n";
 		echo "\t\t\t<select name=\"formEncoding\">\n";
 		echo "\t\t\t\t<option value=\"\"></option>\n";
-		while (list ($key) = each ($data->codemap)) {
+		foreach ($data->codemap as $key => $value) {
 		    echo "\t\t\t\t<option value=\"", htmlspecialchars($key), "\"",
 				($key == $_POST['formEncoding']) ? ' selected="selected"' : '', ">",
 				$misc->printVal($key), "</option>\n";
diff -r 071af26103e4 classes/Misc.php
--- a/classes/Misc.php	Thu Mar 11 18:40:52 2021 +0100
+++ b/classes/Misc.php	Thu Mar 11 18:44:57 2021 +0100
@@ -494,7 +494,7 @@
 				exit;
 			}
 			$this->setServerInfo('platform', $platform, $server_id);
-			$this->setServerInfo('pgVersion', $_connection->conn->pgVersion, $server_id);
+			$this->setServerInfo('pgVersion', $_connection->conn->ServerInfo()['version'], $server_id);
 
 			// Create a database wrapper class for easy manipulation of the
 			// connection.
diff -r 071af26103e4 classes/database/Postgres.php
--- a/classes/database/Postgres.php	Thu Mar 11 18:40:52 2021 +0100
+++ b/classes/database/Postgres.php	Thu Mar 11 18:44:57 2021 +0100
@@ -2629,9 +2629,9 @@
 		$this->fieldClean($sequence);
 		$this->clean($sequence);
 
-		$sql = "SELECT pg_catalog.has_sequence_privilege('{$f_schema}.{$sequence}','SELECT,USAGE')";
-
-		return $this->execute($sql);
+		$sql = "SELECT pg_catalog.has_sequence_privilege('{$f_schema}.{$sequence}','SELECT,USAGE') AS priv";
+
+		return $this->selectField($sql, 'priv');
 	}
 
 	/**
diff -r 071af26103e4 libraries/lib.inc.php
--- a/libraries/lib.inc.php	Thu Mar 11 18:40:52 2021 +0100
+++ b/libraries/lib.inc.php	Thu Mar 11 18:44:57 2021 +0100
@@ -236,7 +236,7 @@
 		$_server_info = $misc->getServerInfo();
 
 		/* starting with PostgreSQL 9.0, we can set the application name */
-		if(isset($_server_info['pgVersion']) && $_server_info['pgVersion'] >= 9)
+		if(isset($_server_info['pgVersion']) && version_compare($_server_info['pgVersion'], '9', '>='))
 			putenv("PGAPPNAME={$appName}_{$appVersion}");
 
 		// Redirect to the login form if not logged in