You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/* If max_memory_limit is not set to unlimited, verify change */
337
-
if (PG(max_memory_limit) !=-1) {
338
-
if (value==-1) {
339
-
zend_error(
340
-
E_WARNING,
341
-
"Failed to set memory_limit to unlimited. memory_limit (currently: "ZEND_LONG_FMT" bytes) cannot be set to unlimited if max_memory_limit ("ZEND_LONG_FMT" bytes) is not unlimited",
342
-
PG(memory_limit),
343
-
PG(max_memory_limit)
344
-
);
345
-
346
-
returnFAILURE;
337
+
if (PG(max_memory_limit) !=-1&& (value==-1||value>PG(max_memory_limit))) {
338
+
if (value!=-1) {
339
+
zend_error(E_WARNING,
340
+
"Failed to set memory_limit to %zd bytes. Setting to max_memory_limit instead (currently: "ZEND_LONG_FMT" bytes)",
341
+
value, PG(max_memory_limit));
347
342
}
348
343
349
-
if (value>PG(max_memory_limit)) {
350
-
zend_error(
351
-
E_WARNING,
352
-
"Failed to set memory_limit to %zd bytes. memory_limit (currently: "ZEND_LONG_FMT" bytes) cannot exceed max_memory_limit ("ZEND_LONG_FMT" bytes)",
Warning: Failed to set memory_limit to unlimited. memory_limit (currently: %d bytes) cannot be set to unlimited ifmax_memory_limit (%d bytes) is not unlimited in %s
0 commit comments