This bug (segfault when loading png from open file with pygame 1.7.1 on python 2.5 or python 2.4) is indeed caused by the SDL dll's (and smpeg.dll) included in the 1.7.1 release being linked against the visual studio 6.0 MSVCRT instead of the Visual Studio 7.1 MSCRT71.dll, like Rene said.
So I rebuilt the SDL libraries with the 2003 toolkit compiler. The SDL sources I used were exact same versions as the ones the 1.7.1 package includes, and the SDL libs were linked to their dependencies statically same as in the 1.7.1 release (better for py2exe). So the rebuilt dll's should be functionally identical to the ones in the pygame 1.7.1 installers on pygame.org, except that the load from file object functions now work. I copied them into my site-packages directory and am using them that way - if anybody else wants to use them, they are here: http://thorbrian.com/SDLDependenciesUsingMSVCR71.zip --- ... I'd try to build a pygame 1.7.x installer for python 2.5 with these fixed sdl dlls, but I don't know how to get 1.7.1 sources or how to modify an installer package On Jun 21, 2007 4:24 PM, René Dudfield <[EMAIL PROTECTED]> wrote: > I think this might be because the 1.7.1release for python2.5 didn't > link against the correct C library. Files can not be shared amongst > the two C libraries. > > > > On 6/22/07, Michael George <[EMAIL PROTECTED]> wrote: > > Hi, I'm running pygame 1.7.1release against python 2.5.1 on various > > windows flavors. When loading an image from a file object using > > pygame.image.load(...) I encounter a segmentation fault. Passing in a > > file name works fine, but since I also want to use the same code with > > tar files, I'd prefer to use file objects. > > > > To reproduce: > > > > import pygame > > pygame.init() > > pygame.image.load( file( 'foo.png' ) ) > > > > Thanks! > > >