Windows API calls that don't work? (Was RE: Stupid stupi
David W Palmer
David_W_Palmer@ccm.jf.intel.com
Mon Mar 24 10:32:00 GMT 1997
Text item:
Colin,
I just tried Smith's code under WinNT 4.0 using GNU-Win32 with no
source modifications.
It compiled and ran properly with commented out code. However, it
failed as he described with the code included.
I also compiled it under VC++ 5.0 (though I had to change STDCALL to
WINAPI). It worked fine in all cases. The modified sample program
still wouldn't work when compiled with GCC.
> Are you using a completely vanilla version of GNU-Win32 or have you
made changes to things (like the startup code for example)? Could you
send me a copy of your silently failing binary?
Out of the box GNU-Win32. I'll send you a mime encoded version of my
gcc generated exe. It's a little large to send to the mailing list.
> PS. Any confirmations on that statement about NT from other readers?
Does stripping an executable make it work? Do you *have* to strip
on NT? Is there a difference between the -s link option and using
strip after linking?
I tried the following commands:
strip test.exe
and
strip test.exe -o tests.exe
Neither cases made any difference.
Running the program from BASH under NTEmacs produces the
following stack dump:
//f/pgming/cygtest$ ./test
(test.exe 1279) In cygwin_except_handler
(test.exe 1279) Exception trapped!
(test.exe 1279) exception C0000005 at 4194
(test.exe 1279) exception: ax 0 bx 240FB00 cx 240FDFC dx A00115C
(test.exe 1279) exception: si 5 di 100113BF bp 240F258 sp 240F24C
(test.exe 1279) exception is: STATUS_ACCESS_VIOLATION
(test.exe 1279) Stack trace:
(test.exe 1279) frame 0: sp = 0x240F080, pc = 0x1001282A
(test.exe 1279) frame 1: sp = 0x240F09C, pc = 0x77F94072
(test.exe 1279) frame 2: sp = 0x240F0C0, pc = 0x77F88A53
(test.exe 1279) frame 3: sp = 0x240F14C, pc = 0x77F75E82
(test.exe 1279) frame 4: sp = 0x240F258, pc = 0x10011BEB
(test.exe 1279) frame 5: sp = 0x240FF9C, pc = 0x10011BFF
(test.exe 1279) frame 6: sp = 0x240FFA8, pc = 0x4011B0
(test.exe 1279) frame 7: sp = 0x240FFB8, pc = 0x401012
(test.exe 1279) frame 8: sp = 0x240FFC0, pc = 0x77F1AFC1
(test.exe 1279) frame 9: sp = 0x240FFF0, pc = 0x0
(test.exe 1279) End of stack trace
//f/pgming/cygtest$
I compiled with symbols "-O -g" with gcc, then using GDB I set a brake
point on GetTopWindow(). The access violation was generated before it
got to the break point.
BTW: DRS chill. Phill is just trying to help.
Dave
Text item: External Message Header
The following mail header is for administrative use
and may be ignored unless there are problems.
***IF THERE ARE PROBLEMS SAVE THESE HEADERS***.
Precedence: bulk
Sender: owner-gnu-win32@cygnus.com
Content-Transfer-Encoding: 7bit
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Date: Mon, 24 Mar 1997 15:52:54 +0900
Subject: Windows API calls that don't work? (Was RE: Stupid stupid question :/)
Cc: "'GNU-Win32'" <gnu-win32@cygnus.com>
To: "'A. Phillip Smith'" <asmith@www.aeinc.com>
From: Colin Peters <colin@bird.fu.is.saga-u.ac.jp>
Message-ID: < 01BC386B.709FACA0@gbird0 >
Received: by gbird0 with Microsoft Mail
id < 01BC386B.709FACA0@gbird0 >; Mon, 24 Mar 1997 15:52:56 +0900
Received: from gbird0 ([133.49.23.250]) by bird.fu.is.saga-u.ac.jp (8.8.2/3.3W7-
bird) with SMTP id PAA10839; Mon, 24 Mar 1997 15:53:11 +0900 (JST)
Received: from bird.fu.is.saga-u.ac.jp (bird.fu.is.saga-u.ac.jp [133.49.23.129])
by cygnus.com (8.8.5/8.8.5) with ESMTP id WAA08904
for <gnu-win32@cygnus.com>; Sun, 23 Mar 1997 22:54:42 -0800 (PST)
Received: (from daemon@localhost)
by cygnus.com (8.8.5/8.8.5) id WAA08913
for gnu-win32-outgoing; Sun, 23 Mar 1997 22:54:59 -0800 (PST)
Received: from cygnus.com (cygnus.com [205.180.230.20]) by mailbag.jf.intel.com
(8.8.5/8.7.3) with ESMTP id GAA20943; Mon, 24 Mar 1997 06:25:38 -0800 (PST)
Received: from mailbag.jf.intel.com (mailbag.jf.intel.com [134.134.248.4]) by re
lay.jf.intel.com (8.7.6/8.7.3) with ESMTP id GAA06921; Mon, 24 Mar 1997 06:23:18
-0800 (PST)
Return-Path: gnu-win32-owner@cygnus.com
-
For help on using this list, send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".
More information about the Cygwin
mailing list