mem/oom: call WEXITSTATUS() only if WIFEXITED() returned true

Only when WIFEXITED() returned true that WEXITSTATUS() can return a
meanful result. So we should check WIFEXITED() first.

Signed-off-by: Han Pingtian <hanpt@linux.vnet.ibm.com>
Reviewed-by: Jan Stancek <jstancek@redhat.com>
1 file changed