From 6dc5c8a75b8ad0aea911c0236e4fdb35e1e0839f Mon Sep 17 00:00:00 2001 From: YAMAMOTO Mitsuharu Date: Mon, 1 May 2006 01:13:42 +0000 Subject: [PATCH] (unexec): Error if trying unexec from dumped executable. --- src/unexmacosx.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/unexmacosx.c b/src/unexmacosx.c index 4ca0be829a2..f65fd9cbc22 100644 --- a/src/unexmacosx.c +++ b/src/unexmacosx.c @@ -1021,6 +1021,9 @@ void unexec (char *outfile, char *infile, void *start_data, void *start_bss, void *entry_address) { + if (in_dumped_exec) + unexec_error ("Unexec from a dumped executable is not supported."); + infd = open (infile, O_RDONLY, 0); if (infd < 0) { -- 2.39.5