diff options
author | Paul Arthur <paul.arthur@flowerysong.com> | 2013-05-15 22:16:20 -0400 |
---|---|---|
committer | Paul Arthur <paul.arthur@flowerysong.com> | 2013-05-15 22:16:20 -0400 |
commit | f0454c03e504becf67661462347922f7dbea9e55 (patch) | |
tree | b7132fc2cbf50f93b1b632c7304baca9a287eb1b /lib | |
parent | 1105e0487fea666944a9cad887dbbff9e5c16a9f (diff) | |
download | ampache-f0454c03e504becf67661462347922f7dbea9e55.tar.gz ampache-f0454c03e504becf67661462347922f7dbea9e55.tar.bz2 ampache-f0454c03e504becf67661462347922f7dbea9e55.zip |
Set the memory_limit to at least 32M
'32' != '32M'
Diffstat (limited to 'lib')
-rw-r--r-- | lib/init.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/init.php b/lib/init.php index eddc306f..fb1b9201 100644 --- a/lib/init.php +++ b/lib/init.php @@ -121,8 +121,10 @@ if (substr($post_size,strlen($post_size)-1,strlen($post_size)) != 'M') { // In case the local setting is 0 ini_set('session.gc_probability','5'); -if (!isset($results['memory_limit']) || $results['memory_limit'] < 32) { - $results['memory_limit'] = 32; +if (!isset($results['memory_limit']) || + (UI::unformat_bytes($results['memory_limit']) < UI::unformat_bytes('32M')) +) { + $results['memory_limit'] = '32M'; } set_memory_limit($results['memory_limit']); |