This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: STATUS_ACCESS_VIOLATION in strlen running a vanilla uw-imapd
- From: Christopher Faylor <cgf-use-the-mailinglist-please at cygwin dot com>
- To: cygwin at cygwin dot com
- Date: Wed, 2 Jun 2010 10:04:22 -0400
- Subject: Re: STATUS_ACCESS_VIOLATION in strlen running a vanilla uw-imapd
- References: <1275486371.5031.1378094543@webmail.messagingengine.com>
- Reply-to: cygwin at cygwin dot com
On Wed, Jun 02, 2010 at 03:46:11PM +0200, cw@tocaido.net wrote:
>Hello,
>
>I am trying to compile the latest release of uw-imapd under Cygwin and
>Windows XP but the program crash after the first command.
>
>This is with the vanilla source from upstream. I know that it is not
>supposed to work very well but yesterday I did the same thing on a
>Windows Seven box and I did not have any problem.
>
>This is the output from ldd:
>
>[15:06][/tmp/imap-2007e/imapd] > ldd ./imapd.exe
> ntdll.dll => /cygdrive/c/WINDOWS/system32/ntdll.dll (0x7c900000)
> kernel32.dll => /cygdrive/c/WINDOWS/system32/kernel32.dll
> (0x7c800000)
> cygwin1.dll => /usr/bin/cygwin1.dll (0x61000000)
> ADVAPI32.DLL => /cygdrive/c/WINDOWS/system32/ADVAPI32.DLL
> (0x77dd0000)
> RPCRT4.dll => /cygdrive/c/WINDOWS/system32/RPCRT4.dll
> (0x77e70000)
> Secur32.dll => /cygdrive/c/WINDOWS/system32/Secur32.dll
> (0x77fe0000)
>
>(I am not using the SSL option)
>
>Here is the stackdump:
>
>Exception: STATUS_ACCESS_VIOLATION at eip=611097F3
>eax=4D61696C ebx=00000000 ecx=FFFFFFFF edx=4D61696C esi=00000001
>edi=4D61696C
>ebp=0022B778 esp=0022B774
>program=C:\cygwin\tmp\imap-2007e\imapd\imapd.exe, pid 1560, thread main
>cs=001B ds=0023 es=0023 fs=003B gs=0000 ss=0023
>Stack trace:
>Frame Function Args
>0022B778 611097F3 (4D61696C, 0022BA3A, 00470CC9, 00000001)
>0022BA58 6113E916 (0022D000, 0022BA78, 00470CC6, 0022BB00)
>0022BAE8 61114064 (0022BB00, 00470CC6, 008599A0, 4D61696C)
>0022BF08 610BC826 (00469DC0, 00000000, 00000000, 00000000)
>0022BF38 00441A76 (0022BFC0, 00469DC0, 00000000, 00000000)
>0022C3C8 0040548A (00000000, 00469546, 00000708, 00869B90)
>0022CD28 00407952 (00000001, 008598C0, 008480E0, 00008000)
>0022CD98 61006E73 (00000000, 0022CDD4, 61006720, 7FFDC000)
>End of stack trace
>
>Using GDB on a running program:
>
>[15:33][/tmp/imap-2007e/imapd] > gdb ./imapd.exe
>GNU gdb 6.8.0.20080328-cvs (cygwin-special)
>[...]
>This GDB was configured as "i686-pc-cygwin"...
>(gdb) run
>Starting program: /tmp/imap-2007e/imapd/imapd.exe
>[New thread 2592.0x5cc]
>[New thread 2592.0x7c0]
>* PREAUTH [CAPABILITY IMAP4REV1 I18NLEVEL=1 LITERAL+ IDLE UIDPLUS
>NAMESPACE CHILDREN MAILBOX-REFERRALS BINARY UNSELECT ESEARCH WITHIN SCAN
>SORT THREAD=REFERENCES THREAD=ORDEREDSUBJECT MULTIAPPEND]
>Pre-authenticated user dente bfmi246pc IMAP4rev1 2007e.404 at Wed, 2 Jun
>2010 15:33:48 +0200
>[New thread 2592.0x84c]
>aaa hhh
>
>Program received signal SIGSEGV, Segmentation fault.
>0x611097f3 in strlen () from /usr/bin/cygwin1.dll
>(gdb) bt
>#0 0x611097f3 in strlen () from /usr/bin/cygwin1.dll
>#1 0x7c85ada0 in OutputDebugStringA () from
>/cygdrive/c/WINDOWS/system32/kernel32.dll
>#2 0x40010006 in ?? ()
>#3 0x00000000 in ?? ()
>
>(I have used "aaa hhh" as an example nonsensical comman, but I get the
>crash whatever I use as an input)
>
>
>Using GDB on a coredump ends with:
>
>#0 0x611097f3 in strlen () from C:\cygwin\bin\cygwin1.dll
>
>
>Now I am stuck ... Seeing that it is not a program guaranteed to work
>under cygwin I would not have asked on the mailing list, but for the
>fact that a) it is working under Win7 but not under WinXP and b) GDB
>seems to say that the problem is in the cygwin1.dll.
If it's actually dying in strlen() (which is debatable) then that
wouldn't be a Cygwin problem. It would be a problem with a program
sending garbage to strlen().
Unfortunately, you need to do quite a bit more debugging of the problem
than just looking at a stack trace. I'd suggest setting breakpoints
throughout the code and stepping around to see what function is dying.
cgf
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple