$this->gam = $gam;
}
- function &myclone()
+ function myclone()
{
$ret = new Ptsgam($this->username, $this->pts, $this->gam);
define(SUBTY_FREQ_HI, 1);
-function placings_show(&$user)
+function placings_show($user)
{
$mtime = placing_time();
$tm = placing_date($mtime);
function placing_time_pgsql()
{
GLOBAL $G_dbpfx;
- // FIXME: now create can return FALSE
- $bdb = BriskDB::create();
+
+ if (($bdb = BriskDB::create()) == FALSE) {
+ log_crit("placing: database connection failed");
+ return (FALSE);
+ }
$mti_sql = sprintf("SELECT CAST(EXTRACT(EPOCH FROM mtime) AS INTEGER) as mtime
FROM %sbin5_places_mtime WHERE code = 0;", $G_dbpfx);
}
-function placing_show_file(&$user, $ty, $subty)
+function placing_show_file($user, $ty, $subty)
{
$tail = FALSE;
//
//
-function placing_show_pgsql(&$user, $ty, $subty)
+function placing_show_pgsql($user, $ty, $subty)
{
GLOBAL $G_dbpfx;
- // FIXME: now create can return FALSE
- $bdb = BriskDB::create();
+ if (($bdb = BriskDB::create()) == FALSE) {
+ log_crit("placing: database connection failed");
+ return ("");
+ }
if ($user != FALSE) {
$pla_sql = sprintf("SELECT * from %sbin5_places where type = %d AND (rank <= %d OR ucode = '%s');",
return ($ret);
}
-function placing_show(&$user, $ty, $subty)
+function placing_show($user, $ty, $subty)
{
GLOBAL $G_dbasetype;