delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/02/03/14:19:04

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Date: Tue, 3 Feb 2004 14:18:00 -0500
From: Jason Tishler <jason AT tishler DOT net>
To: cygwin AT cygwin DOT com
Subject: Re: Python error under Cygwin - threading module
Message-ID: <20040203191759.GA1424@tishler.net>
Mail-Followup-To: cygwin AT cygwin DOT com
References: <20040130130225 DOT 61664 DOT qmail AT web21101 DOT mail DOT yahoo DOT com>
Mime-Version: 1.0
In-Reply-To: <20040130130225.61664.qmail@web21101.mail.yahoo.com>
User-Agent: Mutt/1.4i
X-IsSubscribed: yes

--PEIAKu/WMn1b1Hv9
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

On Fri, Jan 30, 2004 at 05:02:25AM -0800, Artur de Sousa Rocha wrote:
> Sometimes when I launch my script under Cygwin, I get strange error
> messages like:
> 
>       2 [win] python 1912 Winmain: Cannot register window class
> 
> Sometimes all of the threads run OK, otherwise after the "correct"
> ones finish the console stops responding anyway. No problems directly
> under Windows, and /lib/python2.3/test/test_threading.py works fine
> too. What is wrong?

I don't know, but I have some more (albeit not much more) information to
contribute.  If I patch Cygwin with the attached, then I get the
following:

    8 [win] python 2144 Winmain: Cannot register window class, Win32 error 1410

We also have the following:

    $ fgrep 1410 /usr/include/w32api/winerror.h 
    #define ERROR_CLASS_ALREADY_EXISTS 1410L

<WAG>
So, it seems that Cygwin is calling RegisterClass() with the same
WNDCLASS more than once.
</WAG>

Does the above ring any bells?

Thanks,
Jason

-- 
PGP/GPG Key: http://www.tishler.net/jason/pubkey.asc or key servers
Fingerprint: 7A73 1405 7F2B E669 C19D  8784 1AFD E4CC ECF4 8EF6

--PEIAKu/WMn1b1Hv9
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="window.cc.diff"

Index: window.cc
===================================================================
RCS file: /cvs/src/src/winsup/cygwin/window.cc,v
retrieving revision 1.28
diff -u -p -r1.28 window.cc
--- window.cc	14 Dec 2003 07:09:22 -0000	1.28
+++ window.cc	3 Feb 2004 19:14:59 -0000
@@ -97,7 +97,7 @@ Winmain (VOID *)
 
   if (!RegisterClass (&wc))
     {
-      system_printf ("Cannot register window class");
+      system_printf ("Cannot register window class, %E");
       return FALSE;
     }
 


--PEIAKu/WMn1b1Hv9
Content-Type: text/plain; charset=us-ascii

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/
--PEIAKu/WMn1b1Hv9--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019