~ubuntu-branches/ubuntu/saucy/gstreamer0.10/saucy

« back to all changes in this revision

Viewing changes to gst/gstsystemclock.c

  • Committer: Package Import Robot
  • Author(s): Sebastian Dröge
  • Date: 2011-12-11 18:52:12 UTC
  • mfrom: (32.1.14 experimental)
  • Revision ID: package-import@ubuntu.com-20111211185212-3k215ps4qtyz2qa5
Tags: 0.10.35.2-1
* New upstream pre-release:
  + debian/control.in:
    - Build-depend on GLib >= 2.24.
  + debian/patches/99_ltmain_as-needed.patch:
    - Refreshed to apply cleanly again.
  + debian/libgstreamer.symbols:
    - Update symbols file with new API.
* debian/rules:
  + Remove all dependency_libs from the .la files (Closes: #633319).
* debian/control.in:
  + Put GI package into section introspection.
* debian/compat,
  debian/control.in,
  debian/gir1.2-gstreamer.install,
  debian/libgstreamer-dev.install,
  debian/libgstreamer.install,
  debian/patches/79_multiarch-backwards-compat.patch,
  debian/patches/80_ia32-hack.patch,
  debian/rules:
  + Transition package to multi-arch (Closes: #647481).
    Patch taken from the Ubuntu package.

Show diffs side-by-side

added added

removed removed

Lines of Context:
55
55
#  define EWOULDBLOCK EAGAIN    /* This is just to placate gcc */
56
56
#endif /* G_OS_WIN32 */
57
57
 
58
 
#define GET_ENTRY_STATUS(e)          (g_atomic_int_get(&GST_CLOCK_ENTRY_STATUS(e)))
 
58
#define GET_ENTRY_STATUS(e)          ((GstClockReturn) g_atomic_int_get(&GST_CLOCK_ENTRY_STATUS(e)))
59
59
#define SET_ENTRY_STATUS(e,val)      (g_atomic_int_set(&GST_CLOCK_ENTRY_STATUS(e),(val)))
60
60
#define CAS_ENTRY_STATUS(e,old,val)  (G_ATOMIC_INT_COMPARE_AND_EXCHANGE(\
61
61
                                       (&GST_CLOCK_ENTRY_STATUS(e)), (old), (val)))
237
237
 
238
238
  switch (prop_id) {
239
239
    case PROP_CLOCK_TYPE:
240
 
      sysclock->priv->clock_type = g_value_get_enum (value);
 
240
      sysclock->priv->clock_type = (GstClockType) g_value_get_enum (value);
241
241
      GST_CAT_DEBUG (GST_CAT_CLOCK, "clock-type set to %d",
242
242
          sysclock->priv->clock_type);
243
243
      break;
328
328
  if (sysclock->priv->wakeup_count == 0) {
329
329
    GST_CAT_DEBUG (GST_CAT_CLOCK, "writing control");
330
330
    while (!gst_poll_write_control (sysclock->priv->timer)) {
331
 
      g_warning
332
 
          ("gstsystemclock: write control failed in wakeup_async, trying again : %d:%s\n",
333
 
          errno, g_strerror (errno));
 
331
      if (errno == EAGAIN || errno == EWOULDBLOCK || errno == EINTR) {
 
332
        g_warning
 
333
            ("gstsystemclock: write control failed in wakeup_async, trying again: %d:%s\n",
 
334
            errno, g_strerror (errno));
 
335
      } else {
 
336
        g_critical
 
337
            ("gstsystemclock: write control failed in wakeup_async: %d:%s\n",
 
338
            errno, g_strerror (errno));
 
339
        return;
 
340
      }
334
341
    }
335
342
  }
336
343
  sysclock->priv->wakeup_count++;
728
735
  if (G_LIKELY (clock->thread != NULL))
729
736
    return TRUE;                /* Thread already running. Nothing to do */
730
737
 
 
738
#if !GLIB_CHECK_VERSION (2, 31, 0)
731
739
  clock->thread = g_thread_create ((GThreadFunc) gst_system_clock_async_thread,
732
740
      clock, TRUE, &error);
 
741
#else
 
742
  clock->thread = g_thread_try_new ("GstSystemClock",
 
743
      (GThreadFunc) gst_system_clock_async_thread, clock, &error);
 
744
#endif
 
745
 
733
746
  if (G_UNLIKELY (error))
734
747
    goto no_thread;
735
748