[gstreamer-bugs] [Bug 544776] New: [win32] binary registry may fail if glib is using a different c runtime

GStreamer (bugzilla.gnome.org) bugzilla-daemon at bugzilla.gnome.org
Fri Jul 25 15:58:21 PDT 2008


If you have any questions why you received this email, please see the text at
the end of this email. Replies to this email are NOT read, please see the text
at the end of this email. You can add comments to this bug at:
  http://bugzilla.gnome.org/show_bug.cgi?id=544776

  GStreamer | gstreamer (core) | Ver: HEAD CVS
           Summary: [win32] binary registry may fail if glib is using a
                    different c runtime
           Product: GStreamer
           Version: HEAD CVS
          Platform: Other
        OS/Version: Windows
            Status: UNCONFIRMED
          Severity: normal
          Priority: Normal
         Component: gstreamer (core)
        AssignedTo: gstreamer-bugs at lists.sourceforge.net
        ReportedBy: msmith at xiph.org
         QAContact: gstreamer-bugs at lists.sourceforge.net
                CC: t.i.m at zen.co.uk
     GNOME version: Unspecified
   GNOME milestone: Unspecified


On win32, various things are local to the C runtime, including file
descriptors. Thus, if glib and gstreamer are linked against different C
runtimes (a common occurance), it's unsafe to open a file descriptor in glib,
and use it from gstreamer. 

The binary registry uses g_mkstmp() to open a temp file, returning a file
descriptor from glib, and then writes to it and closes it locally.

This causes assertions in debug builds, and crashes elsewhere (if glib is using
a different c runtime).

The patch to come refactors some of the code so that the existing code is used
for non-win32 platforms, and for win32, the binary registry is written to a
memory buffer, then written to the file with g_file_set_contents() (which is
entirely within glib).


-- 
See http://bugzilla.gnome.org/page.cgi?id=email.html for more info about why you received
this email, why you can't respond via email, how to stop receiving
emails (or reduce the number you receive), and how to contact someone
if you are having problems with the system.

You can add comments to this bug at http://bugzilla.gnome.org/show_bug.cgi?id=544776.




More information about the Gstreamer-bugs mailing list