mirror of
https://github.com/Yetangitu/ampache
synced 2025-10-06 03:49:56 +02:00
Issue #559, corrected the variables as suggested by quack23.
This commit is contained in:
parent
70e99db5b6
commit
074c00c304
1 changed files with 101 additions and 101 deletions
|
@ -203,10 +203,10 @@ function check_config_values($conf) {
|
||||||
*/
|
*/
|
||||||
function check_php_memory() {
|
function check_php_memory() {
|
||||||
|
|
||||||
$current = ini_get('memory_limit');
|
$current_memory = ini_get('memory_limit');
|
||||||
$current = substr($current_memory,0,strlen($current_memory)-1);
|
$current_memory = substr($current_memory,0,strlen($current_memory)-1);
|
||||||
|
|
||||||
if (intval($current) < 48) {
|
if (intval($current_memory) < 48) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -239,9 +239,9 @@ function check_php_timelimit() {
|
||||||
function check_putenv() {
|
function check_putenv() {
|
||||||
|
|
||||||
/* Check memory */
|
/* Check memory */
|
||||||
$current = ini_get('memory_limit');
|
$current_memory = ini_get('memory_limit');
|
||||||
$current = substr($current_memory,0,strlen($current_memory)-1);
|
$current_memory = substr($current_memory,0,strlen($current_memory)-1);
|
||||||
$new_limit = ($current+16) . "M";
|
$new_limit = ($current_memory+16) . "M";
|
||||||
|
|
||||||
/* Bump it by 16 megs (for getid3)*/
|
/* Bump it by 16 megs (for getid3)*/
|
||||||
if (!ini_set(memory_limit,$new_limit)) {
|
if (!ini_set(memory_limit,$new_limit)) {
|
||||||
|
@ -249,9 +249,9 @@ function check_putenv() {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Make sure it actually worked
|
// Make sure it actually worked
|
||||||
$current = ini_get('memory_limit');
|
$new_memory = ini_get('memory_limit');
|
||||||
|
|
||||||
if ($new_limit != $current) {
|
if ($new_limit != $new_memory) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue