From: Enrico Tassi Date: Tue, 21 Mar 2006 13:58:58 +0000 (+0000) Subject: go X-Git-Tag: make_still_working~7485 X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=commitdiff_plain;ds=sidebyside;h=0a2a17e3a4d180ff8a23ef4bd56a5d05f2a303aa;p=helm.git go --- diff --git a/helm/software/matita/scripts/public_html/bench.php b/helm/software/matita/scripts/public_html/bench.php index 0a3d4fde5..84f27d6e2 100644 --- a/helm/software/matita/scripts/public_html/bench.php +++ b/helm/software/matita/scripts/public_html/bench.php @@ -173,7 +173,17 @@ function links_of($name,$q,$limits){ SQL (only one query, ';' if present must terminate the query, no characters allowed after it): - + diff --git a/helm/software/matita/scripts/public_html/common.php b/helm/software/matita/scripts/public_html/common.php index 48121b549..0e7962abf 100644 --- a/helm/software/matita/scripts/public_html/common.php +++ b/helm/software/matita/scripts/public_html/common.php @@ -50,8 +50,9 @@ function printer($q){ function query($q,$f) { $db = mysql_pconnect("localhost","helm"); mysql_select_db("matita"); + $q = preg_replace("/\n/"," ",$q); if (!preg_match("/^(select|describe)[^\n;]*;?$/i",$q)) { - echo "Query not allowed!"; + die("Query not allowed!
" . $q . "
"); return; } $rc = mysql_query($q,$db);