/* unexec for GNU Emacs on Windows NT.
- Copyright (C) 1994, 2001, 2002, 2003, 2004, 2005,
- 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
+ Copyright (C) 1994, 2001-2012 Free Software Foundation, Inc.
This file is part of GNU Emacs.
*/
#include <config.h>
+#include "unexec.h"
#include <stdio.h>
#include <fcntl.h>
is finished. */
#ifdef HAVE_NTGUI
/* determine WinMain args like crt0.c does */
- hinst = GetModuleHandle(NULL);
- lpCmdLine = GetCommandLine();
+ hinst = GetModuleHandle (NULL);
+ lpCmdLine = GetCommandLine ();
nCmdShow = SW_SHOWDEFAULT;
#endif
mainCRTStartup ();
#define PTR_TO_RVA(ptr) ((DWORD)(ptr) - (DWORD) GetModuleHandle (NULL))
#define RVA_TO_PTR(var,section,filedata) \
- ((void *)(RVA_TO_OFFSET(var,section) + (filedata).file_base))
+ ((void *)(RVA_TO_OFFSET (var,section) + (filedata).file_base))
#define PTR_TO_OFFSET(ptr, pfile_data) \
((unsigned char *)(ptr) - (pfile_data)->file_base)
{
PIMAGE_DOS_HEADER dos_header;
PIMAGE_NT_HEADERS nt_header;
- PIMAGE_SECTION_HEADER section;
int overlap;
dos_header = (PIMAGE_DOS_HEADER) p_infile->file_base;
/* Dump out .data and .bss sections into a new executable. */
-int
+void
unexec (const char *new_name, const char *old_name)
{
file_data in_file, out_file;
close_file_data (&in_file);
close_file_data (&out_file);
-
- return 0;
}
/* eof */
-