Mercurial > hg > xemacs-beta
comparison src/win32.c @ 4854:95c4ced5c07c
fix compile problems
-------------------- ChangeLog entries follow: --------------------
src/ChangeLog addition:
2010-01-14 Ben Wing <ben@xemacs.org>
* glyphs-eimage.c:
Turn on fixes for conflicts between jmorecfg.h and windows.h on
Cygwin, too.
* emacs.c (debug_can_access_memory):
* lisp.h:
Declare function const void * to avoid warnings.
* sysfile.h:
Include syswindows.h on Windows to avoid problems using things like
PATHNAME_CONVERT_OUT.
* sysfile.h (X_OK):
* dialog-msw.c (handle_directory_proc):
* dialog-msw.c (handle_directory_dialog_box):
* nt.c (Fmswindows_short_file_name):
* sysdep.c (qxe_allocating_getcwd):
* syswindows.h (LOCAL_FILE_FORMAT_TO_TSTR):
* unexcw.c (unexec):
* unexnt.c (_start):
* win32.c (mswindows_read_link_1):
Rename PATH_MAX_EXTERNAL to PATH_MAX_TSTR to reflect its actual
semantics.
* unexcw.c:
Remove include of syswindows.h that had been added because
sysfile.h didn't include it.
author | Ben Wing <ben@xemacs.org> |
---|---|
date | Thu, 14 Jan 2010 01:25:16 -0600 |
parents | b3ea9c582280 |
children | c356806cc933 |
comparison
equal
deleted
inserted
replaced
4853:d35e231d347d | 4854:95c4ced5c07c |
---|---|
519 XECOMID (IID_IPersistFile), | 519 XECOMID (IID_IPersistFile), |
520 &VOIDP_CAST (ppf)) == S_OK) | 520 &VOIDP_CAST (ppf)) == S_OK) |
521 { | 521 { |
522 Extbyte *fname_unicode; | 522 Extbyte *fname_unicode; |
523 WIN32_FIND_DATAW wfd; | 523 WIN32_FIND_DATAW wfd; |
524 LPWSTR resolved = alloca_array (WCHAR, PATH_MAX_EXTERNAL + 1); | 524 LPWSTR resolved = alloca_array (WCHAR, PATH_MAX_TCHAR + 1); |
525 | 525 |
526 /* Always Unicode. Not obvious from the | 526 /* Always Unicode. Not obvious from the |
527 IPersistFile documentation, but look under | 527 IPersistFile documentation, but look under |
528 "Shell Link" for example code. */ | 528 "Shell Link" for example code. */ |
529 fname_unicode = fnameext; | 529 fname_unicode = fnameext; |
544 even if it's actually the other way around. */ | 544 even if it's actually the other way around. */ |
545 #if defined (CYGWIN_HEADERS) && W32API_INSTALLED_VER < W32API_VER(2,2) | 545 #if defined (CYGWIN_HEADERS) && W32API_INSTALLED_VER < W32API_VER(2,2) |
546 /* Another Cygwin prototype error, | 546 /* Another Cygwin prototype error, |
547 fixed in v2.2 of w32api */ | 547 fixed in v2.2 of w32api */ |
548 XECOMCALL4 (psl, GetPath, (LPSTR) resolved, | 548 XECOMCALL4 (psl, GetPath, (LPSTR) resolved, |
549 PATH_MAX_EXTERNAL, &wfd, 0) | 549 PATH_MAX_TCHAR, &wfd, 0) |
550 #else | 550 #else |
551 XECOMCALL4 (psl, GetPath, resolved, | 551 XECOMCALL4 (psl, GetPath, resolved, |
552 PATH_MAX_EXTERNAL, &wfd, 0) | 552 PATH_MAX_TCHAR, &wfd, 0) |
553 #endif | 553 #endif |
554 == S_OK) | 554 == S_OK) |
555 TSTR_TO_C_STRING_MALLOC (resolved, retval); | 555 TSTR_TO_C_STRING_MALLOC (resolved, retval); |
556 | 556 |
557 XECOMCALL0 (ppf, Release); | 557 XECOMCALL0 (ppf, Release); |
577 XECOMID (IID_IPersistFile), | 577 XECOMID (IID_IPersistFile), |
578 &VOIDP_CAST (ppf)) == S_OK) | 578 &VOIDP_CAST (ppf)) == S_OK) |
579 { | 579 { |
580 Extbyte *fname_unicode; | 580 Extbyte *fname_unicode; |
581 WIN32_FIND_DATAA wfd; | 581 WIN32_FIND_DATAA wfd; |
582 LPSTR resolved = alloca_array (CHAR, PATH_MAX_EXTERNAL + 1); | 582 LPSTR resolved = alloca_array (CHAR, PATH_MAX_TCHAR + 1); |
583 | 583 |
584 /* Always Unicode. Not obvious from the | 584 /* Always Unicode. Not obvious from the |
585 IPersistFile documentation, but look under | 585 IPersistFile documentation, but look under |
586 "Shell Link" for example code. */ | 586 "Shell Link" for example code. */ |
587 C_STRING_TO_EXTERNAL (fname, fname_unicode, | 587 C_STRING_TO_EXTERNAL (fname, fname_unicode, |
589 | 589 |
590 if (XECOMCALL2 (ppf, Load, | 590 if (XECOMCALL2 (ppf, Load, |
591 (LPWSTR) fname_unicode, | 591 (LPWSTR) fname_unicode, |
592 STGM_READ) == S_OK | 592 STGM_READ) == S_OK |
593 && XECOMCALL4 (psl, GetPath, resolved, | 593 && XECOMCALL4 (psl, GetPath, resolved, |
594 PATH_MAX_EXTERNAL, &wfd, 0) == S_OK) | 594 PATH_MAX_TCHAR, &wfd, 0) == S_OK) |
595 TSTR_TO_C_STRING_MALLOC (resolved, retval); | 595 TSTR_TO_C_STRING_MALLOC (resolved, retval); |
596 | 596 |
597 XECOMCALL0 (ppf, Release); | 597 XECOMCALL0 (ppf, Release); |
598 } | 598 } |
599 | 599 |