PLD-doc: PLD_www_res/buildlogs.sql/index.php, PLD_www_res/buildlog...

witekfl witekfl at pld-linux.org
Sat Nov 24 18:00:51 CET 2007


Author: witekfl                      Date: Sat Nov 24 17:00:51 2007 GMT
Module: PLD-doc                       Tag: HEAD
---- Log message:
- proper catching of PDO exceptions

---- Files affected:
PLD-doc/PLD_www_res/buildlogs.sql:
   index.php (1.3 -> 1.4) , addlog.php (1.3 -> 1.4) 

---- Diffs:

================================================================
Index: PLD-doc/PLD_www_res/buildlogs.sql/index.php
diff -u PLD-doc/PLD_www_res/buildlogs.sql/index.php:1.3 PLD-doc/PLD_www_res/buildlogs.sql/index.php:1.4
--- PLD-doc/PLD_www_res/buildlogs.sql/index.php:1.3	Sat Nov 24 12:10:45 2007
+++ PLD-doc/PLD_www_res/buildlogs.sql/index.php	Sat Nov 24 18:00:46 2007
@@ -466,7 +466,7 @@
 	try {
 		$dbh = new PDO($database);
 	} catch (PDOException $e) {
-		mydie("new PDO: " . $e.getMessage());
+		mydie("new PDO: " . $e->getMessage());
 	}
 	$f = false;
 	foreach ($dbh->query("SELECT arch_id, result, spec FROM logs WHERE log_id = $l LIMIT 1") as $row) {
@@ -949,7 +949,7 @@
 	try {
 		$dbh = new PDO("$database");
 	} catch (PDOException $e) {
-		mydie("new PDO: " . $e.getMessage());
+		mydie("new PDO: " . $e->getMessage());
 	}
 	$result = $dbh->query("$query")->fetchAll();
 

================================================================
Index: PLD-doc/PLD_www_res/buildlogs.sql/addlog.php
diff -u PLD-doc/PLD_www_res/buildlogs.sql/addlog.php:1.3 PLD-doc/PLD_www_res/buildlogs.sql/addlog.php:1.4
--- PLD-doc/PLD_www_res/buildlogs.sql/addlog.php:1.3	Sat Nov 24 12:10:33 2007
+++ PLD-doc/PLD_www_res/buildlogs.sql/addlog.php	Sat Nov 24 18:00:46 2007
@@ -59,7 +59,7 @@
 try {
 	$dbh = new PDO("$database");
 } catch (PDOException $e) {
-	die (e.getMessage());
+	die ($e->getMessage());
 }
 $result = $dbh->query("SELECT log_id FROM logs WHERE spec = '$spec_name' AND arch_id = $arch_id AND result = $result_id LIMIT 1")->fetchAll();
 if (count($result) == 1) {
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/PLD-doc/PLD_www_res/buildlogs.sql/index.php?r1=1.3&r2=1.4&f=u
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/PLD-doc/PLD_www_res/buildlogs.sql/addlog.php?r1=1.3&r2=1.4&f=u



More information about the pld-cvs-commit mailing list