Commit fea1406d authored by Daniel Kiper's avatar Daniel Kiper Committed by Atsushi Kumagai
Browse files

[PATCH v3 2/7] elf: Properly check buf size in get_pt_note_info().



get_pt_note_info() always ignores VMCOREINFO_XEN note because
buf size must be smaller than note size including \0 char.
Usualy this condition is true but when VMCOREINFO_XEN note
is encountered it does not work due to buf size defined
as sizeof("VMCOREINFO_XEN"). This patch fixes that bug
and VMCOREINFO_XEN note living in /proc/vmcore file
could be properly detected now.

v2 - suggestions/fixes:
   - properly check buf size instead of increasing buf size
     (suggested by Andrew Cooper).

Signed-off-by: default avatarDaniel Kiper <daniel.kiper@oracle.com>
parent 8c7c55e1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment