From: Eli Zaretskii Date: Mon, 6 Jun 2005 19:28:27 +0000 (+0000) Subject: (RVA_TO_PTR): New macro. X-Git-Tag: emacs-pretest-22.0.90~9243 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=8747ac3f6853164434eb82c8172c7547b4e32be7;p=emacs.git (RVA_TO_PTR): New macro. --- diff --git a/src/w32proc.c b/src/w32proc.c index 9abee2bf0c2..48b5e2c14a3 100644 --- a/src/w32proc.c +++ b/src/w32proc.c @@ -57,6 +57,11 @@ extern BOOL WINAPI IsValidLocale(LCID, DWORD); #include "syssignal.h" #include "w32term.h" +#define RVA_TO_PTR(var,section,filedata) \ + ((void *)((section)->PointerToRawData \ + + ((DWORD)(var) - (section)->VirtualAddress) \ + + (filedata).file_base)) + /* Control whether spawnve quotes arguments as necessary to ensure correct parsing by child process. Because not all uses of spawnve are careful about constructing argv arrays, we make this behaviour