mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-05-02 19:42:54 +02:00
set_magic_quote_runtime and get_magic_quote_gpc are depreciated and can produce notices from PHP 5.3.
Add a @ to avoid this notices. This functions need to be removed with PHP 6 git-svn-id: http://piwigo.org/svn/branches/2.0@4005 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -136,7 +136,7 @@ function check_upgrade_access_rights($current_release, $username, $password)
|
||||
{
|
||||
global $conf, $page;
|
||||
|
||||
if(!get_magic_quotes_gpc())
|
||||
if(!@get_magic_quotes_gpc())
|
||||
{
|
||||
$username = mysql_real_escape_string($username);
|
||||
}
|
||||
|
||||
@@ -28,13 +28,13 @@ $t1 = explode( ' ', microtime() );
|
||||
$t2 = explode( '.', $t1[0] );
|
||||
$t2 = $t1[1].'.'.$t2[1];
|
||||
|
||||
set_magic_quotes_runtime(0); // Disable magic_quotes_runtime
|
||||
@set_magic_quotes_runtime(0); // Disable magic_quotes_runtime
|
||||
|
||||
//
|
||||
// addslashes to vars if magic_quotes_gpc is off this is a security
|
||||
// precaution to prevent someone trying to break out of a SQL statement.
|
||||
//
|
||||
if( !get_magic_quotes_gpc() )
|
||||
if( !@get_magic_quotes_gpc() )
|
||||
{
|
||||
function sanitize_mysql_kv(&$v, $k)
|
||||
{
|
||||
|
||||
@@ -72,12 +72,12 @@ function execute_sqlfile($filepath, $replaced, $replacing)
|
||||
}
|
||||
}
|
||||
|
||||
set_magic_quotes_runtime(0); // Disable magic_quotes_runtime
|
||||
@set_magic_quotes_runtime(0); // Disable magic_quotes_runtime
|
||||
//
|
||||
// addslashes to vars if magic_quotes_gpc is off this is a security
|
||||
// precaution to prevent someone trying to break out of a SQL statement.
|
||||
//
|
||||
if( !get_magic_quotes_gpc() )
|
||||
if( !@get_magic_quotes_gpc() )
|
||||
{
|
||||
if( is_array($_POST) )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user