OOM Crash log include size of allocation attempt. (#7670)

Since users often post just the crash log in github issues, the log
print that's above it is missing.
No reason not to include the size in the panic message itself.
This commit is contained in:
Oran Agra 2020-08-18 09:53:59 +03:00 committed by GitHub
parent 88662c243d
commit 0f741a9e2d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -5006,7 +5006,8 @@ void loadDataFromDisk(void) {
void redisOutOfMemoryHandler(size_t allocation_size) {
serverLog(LL_WARNING,"Out Of Memory allocating %zu bytes!",
allocation_size);
serverPanic("Redis aborting for OUT OF MEMORY");
serverPanic("Redis aborting for OUT OF MEMORY. Allocating %zu bytes!",
allocation_size);
}
void redisSetProcTitle(char *title) {