From ce816fe4c9d983c42b3e9c25e62606c6bcc56b67 Mon Sep 17 00:00:00 2001 From: "Matteo Nastasi (mop)" Date: Wed, 11 Sep 2013 18:36:57 +0200 Subject: [PATCH] fix errors (wrong params, tables names and so on) --- web/Obj/dbase_pgsql.phh | 2 +- web/Obj/sac-a-push.phh | 2 +- web/briskin5/Obj/briskin5.phh | 2 +- web/briskin5/index_wr.php | 6 +++--- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/web/Obj/dbase_pgsql.phh b/web/Obj/dbase_pgsql.phh index 327a893..bd4dfb3 100644 --- a/web/Obj/dbase_pgsql.phh +++ b/web/Obj/dbase_pgsql.phh @@ -323,7 +323,7 @@ class BriskDB break; } for ($i = 0 ; $i < $n ; $i++) { - $ord_sql = sprintf("INSERT INTO %sbin5_table_order (mcode, ucode, pos) VALUES (%d, %d, %d);", + $ord_sql = sprintf("INSERT INTO %sbin5_table_orders (mcode, ucode, pos) VALUES (%d, %d, %d);", $G_dbpfx, $G_dbpfx, $sql_ttok, $ucode[$i], $i); if (($ord_pg = $this->query($ord_sql)) == FALSE || pg_affected_rows($ord_pg) != 1 ) { log_crit(sprintf("bin5_points_save: failed at insert table order [%s]", $ord_sql)); diff --git a/web/Obj/sac-a-push.phh b/web/Obj/sac-a-push.phh index 0ae856e..ec5abd2 100644 --- a/web/Obj/sac-a-push.phh +++ b/web/Obj/sac-a-push.phh @@ -709,7 +709,7 @@ class Sac_a_push { if ($buf == FALSE || mb_strlen($buf, "ASCII") == 0) { // close socket case if ($buf == FALSE) { - printf("ERROR READING\n"); + printf("INFO: read return false\n"); } if ($sock === $this->list) { printf("Arrivati %d bytes da list\n", mb_strlen($buf, "ASCII")); diff --git a/web/briskin5/Obj/briskin5.phh b/web/briskin5/Obj/briskin5.phh index 12a5230..9e7fa04 100644 --- a/web/briskin5/Obj/briskin5.phh +++ b/web/briskin5/Obj/briskin5.phh @@ -584,7 +584,7 @@ class Bin5_table extends Table { else { log_points($remote_addr, $curtime, $user, "STAT:BRISKIN5:FINISH_GAME", "DATABASE CONNECTION FAILED"); } - log_points($curtime, $user, "STAT:BRISKIN5:FINISH_GAME", $plist); + log_points($remote_addr, $curtime, $user, "STAT:BRISKIN5:FINISH_GAME", $plist); } $this->game_init(&$bri->user); diff --git a/web/briskin5/index_wr.php b/web/briskin5/index_wr.php index 91cf53c..c2cb21c 100644 --- a/web/briskin5/index_wr.php +++ b/web/briskin5/index_wr.php @@ -209,7 +209,7 @@ function bin5_index_wr_main(&$bri, $remote_addr_full, $get, $post, $cookie) /* $table->game_init(&$bri->user); */ - if ($table->rules_engine(&$bri, BIN5_RULES_ABANDON, $user)) { + if ($table->rules_engine(&$bri, $curtime, BIN5_RULES_ABANDON, $user)) { for ($i = 0 ; $i < BIN5_PLAYERS_N ; $i++) { $user_cur = &$bri->user[$table->player[$i]]; @@ -315,7 +315,7 @@ function bin5_index_wr_main(&$bri, $remote_addr_full, $get, $post, $cookie) else if ($table->asta_pla_n == 0) { log_wr("PASSANO TUTTI!"); - if ($table->rules_engine(&$bri, BIN5_RULES_ALLPASS, $user)) { + if ($table->rules_engine(&$bri, $curtime, BIN5_RULES_ALLPASS, $user)) { for ($i = 0 ; $i < BIN5_PLAYERS_N ; $i++) { $user_cur = &$bri->user[$table->player[$i]]; @@ -536,7 +536,7 @@ function bin5_index_wr_main(&$bri, $remote_addr_full, $get, $post, $cookie) /* $table->game_init(&$bri->user); */ - if ($table->rules_engine(&$bri, BIN5_RULES_FINISH, $user)) { + if ($table->rules_engine(&$bri, $curtime, BIN5_RULES_FINISH, $user)) { for ($i = 0 ; $i < BIN5_PLAYERS_N ; $i++) { $user_cur = &$bri->user[$table->player[$i]]; $retar[$i] .= show_table(&$bri,&$user_cur,$user_cur->step+1,TRUE, TRUE); -- 2.17.1