Mercurial > hg > xemacs-beta
comparison src/unexnt.c @ 812:f846c2ef930d
[xemacs-hg @ 2002-04-13 20:31:27 by jhar]
Document that MSVC6 or later required
author | jhar |
---|---|
date | Sat, 13 Apr 2002 20:31:34 +0000 |
parents | 943eaba38521 |
children | a634e3b7acc8 |
comparison
equal
deleted
inserted
replaced
811:7778a469a8ac | 812:f846c2ef930d |
---|---|
126 won't work.) */ | 126 won't work.) */ |
127 if (heap_state == HEAP_UNLOADED) | 127 if (heap_state == HEAP_UNLOADED) |
128 { | 128 { |
129 char executable_path[PATH_MAX]; | 129 char executable_path[PATH_MAX]; |
130 | 130 |
131 if (GetModuleFileName (NULL, executable_path, PATH_MAX) == 0) | 131 if (GetModuleFileNameA (NULL, executable_path, PATH_MAX) == 0) |
132 { | 132 { |
133 exit (1); | 133 exit (1); |
134 } | 134 } |
135 | 135 |
136 /* #### This is super-bogus. When I rename xemacs.exe, | 136 /* #### This is super-bogus. When I rename xemacs.exe, |
223 | 223 |
224 copy_executable_and_dump_data_section (&in_file, &out_file); | 224 copy_executable_and_dump_data_section (&in_file, &out_file); |
225 dump_bss_and_heap (&in_file, &out_file); | 225 dump_bss_and_heap (&in_file, &out_file); |
226 | 226 |
227 /* Patch up header fields; profiler is picky about this. */ | 227 /* Patch up header fields; profiler is picky about this. */ |
228 hImagehelp = LoadLibrary ("imagehlp.dll"); | 228 hImagehelp = LoadLibraryA ("imagehlp.dll"); |
229 if (hImagehelp) | 229 if (hImagehelp) |
230 { | 230 { |
231 PIMAGE_DOS_HEADER dos_header; | 231 PIMAGE_DOS_HEADER dos_header; |
232 PIMAGE_NT_HEADERS nt_header; | 232 PIMAGE_NT_HEADERS nt_header; |
233 | 233 |
532 HANDLE file; | 532 HANDLE file; |
533 HANDLE file_mapping; | 533 HANDLE file_mapping; |
534 void *file_base; | 534 void *file_base; |
535 unsigned long size, upper_size, n_read; | 535 unsigned long size, upper_size, n_read; |
536 | 536 |
537 file = CreateFile (filename, GENERIC_READ, FILE_SHARE_READ, NULL, | 537 file = CreateFileA (filename, GENERIC_READ, FILE_SHARE_READ, NULL, |
538 OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, 0); | 538 OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, 0); |
539 if (file == INVALID_HANDLE_VALUE) | 539 if (file == INVALID_HANDLE_VALUE) |
540 abort (); | 540 abort (); |
541 | 541 |
542 size = GetFileSize (file, &upper_size); | 542 size = GetFileSize (file, &upper_size); |
543 file_mapping = CreateFileMapping (file, NULL, PAGE_WRITECOPY, | 543 file_mapping = CreateFileMappingA (file, NULL, PAGE_WRITECOPY, |
544 0, size, NULL); | 544 0, size, NULL); |
545 if (!file_mapping) | 545 if (!file_mapping) |
546 abort (); | 546 abort (); |
547 | 547 |
548 size = get_committed_heap_size (); | 548 size = get_committed_heap_size (); |
549 file_base = MapViewOfFileEx (file_mapping, FILE_MAP_COPY, 0, | 549 file_base = MapViewOfFileEx (file_mapping, FILE_MAP_COPY, 0, |