Issue #2267407 by alberto56: Fixed Error suppression on json_encode() causes silent fail (no query log, no error message) when there is a memory error.