[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[pygame] Font-Related Segfault



(My apologies if this is a double-post. I didn't get a copy of the
message or see it in the archive, so I'm trying again.)

 I have a pygame program that worked in the past on both Linux and
Windows, but now results in a segfault, at least on Linux.  (I can't
test it on Windows.)
The segfault occurs in this code:

class Font(Resource):
  ....
   def pygame_font(self,size):
       return pygame.font.Font(StringIO.StringIO(self.parts['font']),
size) # Segfaults here


self.parts['font'] is a string containing a truetype font loaded from
a file. I have checked that the string contains the file like it is
supposed too. Any suggestions?