Skip to content

Commit 0f741a9

Browse files
authored
OOM Crash log include size of allocation attempt. (redis#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.
1 parent 88662c2 commit 0f741a9

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/server.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5006,7 +5006,8 @@ void loadDataFromDisk(void) {
50065006
void redisOutOfMemoryHandler(size_t allocation_size) {
50075007
serverLog(LL_WARNING,"Out Of Memory allocating %zu bytes!",
50085008
allocation_size);
5009-
serverPanic("Redis aborting for OUT OF MEMORY");
5009+
serverPanic("Redis aborting for OUT OF MEMORY. Allocating %zu bytes!",
5010+
allocation_size);
50105011
}
50115012

50125013
void redisSetProcTitle(char *title) {

0 commit comments

Comments
 (0)