[gstreamer-bugs] [Bug 623875] New: gstregistrybinary.c compatibility with glib >= 2.25.0

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Thu Jul 8 11:52:33 PDT 2010


https://bugzilla.gnome.org/show_bug.cgi?id=623875
  GStreamer | gstreamer (core) | 0.10.29

           Summary: gstregistrybinary.c compatibility with glib >= 2.25.0
    Classification: Desktop
           Product: GStreamer
           Version: 0.10.29
        OS/Version: Windows
            Status: UNCONFIRMED
          Severity: normal
          Priority: Normal
         Component: gstreamer (core)
        AssignedTo: gstreamer-bugs at lists.sourceforge.net
        ReportedBy: dhoyt at llnl.gov
         QAContact: gstreamer-bugs at lists.sourceforge.net
      GNOME target: ---
     GNOME version: ---


Created an attachment (id=165507)
 View: https://bugzilla.gnome.org/attachment.cgi?id=165507
 Review: https://bugzilla.gnome.org/review?bug=623875&attachment=165507

Patch to use the appropriate glib stat struct for the platform

When compiling gst against glib >= 2.25.0 on MSVC, a warning about incompatible
pointer types is received.

According to the glib documentation
(http://library.gnome.org/devel/glib/unstable/glib-File-Utilities.html#g-stat):

On Windows the Microsoft C libraries have several variants of the stat struct
and stat() function with names like "_stat", "_stat32", "_stat32i64" and
"_stat64i32". The one used here is for 32-bit code the one with 32-bit size and
time fields, specifically called "_stat32". 

In Microsoft's compiler, by default "struct stat" means one with 64-bit time
fields while in MinGW "struct stat" is the legacy one with 32-bit fields. To
hopefully clear up this messs, the gstdio.h header defines a type GStatBuf
which is the appropriate struct type depending on the platform and/or compiler
being used. On POSIX it is just "struct stat", but note that even on POSIX
platforms, "stat" might be a macro.


The attached patch resolves the issue by using GStatBuf in later versions of
glib. The warning subsequently goes away.

I apologize for the format of the patch.

-- 
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.




More information about the Gstreamer-bugs mailing list