Crash on msvcrt mismatch?

Lagarde, Jean jlagarde at
Fri Apr 10 19:41:03 CEST 2009

I'm curious to understand why that matters, but I found out that if I load the modules in the inverse order, everything works fine.

-- Jean

From: Lagarde, Jean
Sent: Friday, April 10, 2009 10:08 AM
To: python-list at
Subject: Crash on msvcrt mismatch?

I don't have much experience writing extension modules, and am looking for pointers to resolve python crashes on Windows.

I've isolated the problem to a python file with the following two lines:

import PyQt4.Qwt5
import C13

That causes Python to crash. If I comment out either one of the two lines, it doesn't. C13 is an extension module wrapping the API for an instrumentation card. I've written test code that uses that C13 module without problems, but that code doesn't use PyQt.

My Python and  PyQt come from the Python(x,y) binary distribution (version 2.1.11). C13 was compiled using mingw and used msvcr71 by default. I noticed that although Python depends on msvcr71 as well, the PyQt modules depend on msvcrt (QtCore4.dll and Qtw.pyd for example). I tried to use msvcrt for C13 as well, but got the same result.

I'm looking for ideas as to what to try next. I'd like to avoid having to build PyQt from source, but if that's the recommendation I'll give it a go.



More information about the Python-list mailing list