From 93ce35434ca5af43a7449e289959543f0a2426fa Mon Sep 17 00:00:00 2001 From: skvalex Date: Thu, 20 Aug 2015 01:06:42 +0300 Subject: [PATCH] Fix a mistype in segment overrange checking Change-Id: Ibea93514aa7ba3b1ac2bc00420f5124fb34f5f66 Signed-off-by: skvalex --- linker/linker_phdr.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linker/linker_phdr.cpp b/linker/linker_phdr.cpp index cf012f424..30bc6fabd 100644 --- a/linker/linker_phdr.cpp +++ b/linker/linker_phdr.cpp @@ -382,7 +382,7 @@ bool ElfReader::LoadSegments() { return false; } - if (file_end >= static_cast(file_size_)) { + if (file_end > static_cast(file_size_)) { DL_ERR("invalid ELF file \"%s\" load segment[%zd]:" " p_offset (%p) + p_filesz (%p) ( = %p) past end of file (0x%" PRIx64 ")", name_, i, reinterpret_cast(phdr->p_offset),