1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-13 04:04:12 +02:00

[ticket/11918] Make sql_freeresult() consistent across all DB drivers

PHPBB3-11918
This commit is contained in:
Patrick Webster
2013-10-14 16:37:23 -05:00
parent 40932c26ea
commit 76ddf1ca41
8 changed files with 11 additions and 10 deletions

View File

@@ -471,7 +471,7 @@ class mssqlnative extends \phpbb\db\driver\mssql_base
$query_id = $this->query_result;
}
if ($cache->sql_exists($query_id))
if ($cache && !is_object($query_id) && $cache->sql_exists($query_id))
{
return $cache->sql_freeresult($query_id);
}
@@ -481,6 +481,7 @@ class mssqlnative extends \phpbb\db\driver\mssql_base
unset($this->open_queries[(int) $query_id]);
return @sqlsrv_free_stmt($query_id);
}
return false;
}