Skip to content
Snippets Groups Projects
  1. Oct 21, 2020
  2. Oct 20, 2020
  3. Oct 13, 2020
    • Mathieu Duponchelle's avatar
      gstvalue: don't write to const char * · e846ef22
      Mathieu Duponchelle authored and Tim-Philipp Müller's avatar Tim-Philipp Müller committed
      Our various deserializing functions require NULL terminators
      to not over consume substrings (eg fields of an array). Instead
      of writing a NULL terminator to the passed-in string, which may
      result in segfaults, make a copy of the substring we're interested
      in.
      
      Fixes #446
      
      Part-of: <!674>
      e846ef22
  4. Oct 12, 2020
  5. Sep 26, 2020
    • Mathieu Duponchelle's avatar
      gst-launch: go back down to GST_STATE_NULL in one step. · 90e9bf14
      Mathieu Duponchelle authored and GStreamer Marge Bot's avatar GStreamer Marge Bot committed
      Going through each state on the way back down to GST_STATE_NULL
      can cause deadlocks, for example:
      
      gst-launch-1.0 audiotestsrc ! valve drop=true ! autoaudiosink
      
      ctrl + C
      
      Hangs forever when going to PAUSED, because the "final" state is
      ASYNC, and the sink blocks waiting for a preroll buffer.
      
      Going straight to NULL addresses this issue, and also helps
      making teardown faster when piping sparse streams to a
      sync sink.
      
      Part-of: <!519>
      90e9bf14
  6. Sep 25, 2020
  7. Sep 24, 2020
  8. Sep 21, 2020
  9. Sep 20, 2020
    • Seungha Yang's avatar
      gst-inspect: Use gst_info_strdup_vprintf to print string · 6b8bb822
      Seungha Yang authored and Tim-Philipp Müller's avatar Tim-Philipp Müller committed
      g_vprintf() will write a string binary to stdout directly using fwrite().
      So, depending on character in the string, fwrite to stdout can
      print broken one but printf family might not cause the issue.
      
      Part-of: <gstreamer/gstreamer!637>
      6b8bb822
    • Edward Hervey's avatar
      queue2: Avoid races when posting buffering messages · b935ac66
      Edward Hervey authored and Tim-Philipp Müller's avatar Tim-Philipp Müller committed
      When posting a buffering message succesfully:
      * Remember the *actual* percentage value that was posted
      * Make sure we only reset the percent_changed variable if the value we just
        posted is indeed different from the current value
      
      Part-of: <gstreamer/gstreamer!632>
      b935ac66
    • Mathieu Duponchelle's avatar
      queue2: don't post unnecessary buffering message, refine locking · fa8ea664
      Mathieu Duponchelle authored and Tim-Philipp Müller's avatar Tim-Philipp Müller committed
      This is a follow up to review comments in !297
      
      + The posting of the buffering message in READY_TO_PAUSED isn't
        needed, removing it made the test fail, but the correct fix
        was simply to link elements together
      
      + Move code to relock the queue and set last_posted_buffering_percent
        and percent_changed inside the buffering_post_lock in create_write().
        This makes locking consistent with post_buffering()
      
      Part-of: <!297>
      fa8ea664
    • Carlos Rafael Giani's avatar
      queue2: Fix missing/dropped buffering messages at startup · f66959c2
      Carlos Rafael Giani authored and Tim-Philipp Müller's avatar Tim-Philipp Müller committed
      This fixes a bug that occurs when an attempt is made to post a buffering
      message before the queue2 was assigned a bus. One common situation where
      this happens is when the use-buffering property is set to TRUE before the
      queue2 was added to a bin.
      
      If the result of gst_element_post_message() is not checked, and the
      aforementioned situation occurs, then last_posted_buffering_percent and
      percent_changed will still be updated, as if posting the message succeeded.
      Later attempts to post again will not do anything because the code then
      assumes that a message with the same percentage was previously posted
      successfully and posting again is redundant.
      
      Updating these variables only if posting succeed and explicitely
      posting a buffering message in the READY->PAUSED state change ensure that
      a buffering message is posted as early as possible.
      
      Part-of: <gstreamer/gstreamer!297>
      f66959c2
  10. Jun 07, 2020
  11. Jun 06, 2020
  12. Jun 04, 2020
  13. Mar 14, 2020
  14. Mar 13, 2020
  15. Feb 26, 2020
  16. Feb 15, 2020
  17. Feb 14, 2020
    • Sebastian Dröge's avatar
      bus: Make setting/replacing/clearing the sync handler thread-safe · a1c0ca3a
      Sebastian Dröge authored and Tim-Philipp Müller's avatar Tim-Philipp Müller committed
      Previously we would use the object lock only for storing the sync
      handler and its user_data in a local variable, then unlock it and only
      then call the sync handler. Between unlocking and calling the sync
      handler it might be unset and the user_data be freed, causing it to be
      called with a freed pointer.
      
      To prevent this add a refcounting wrapper struct around the sync
      handler, hold the object lock while retrieving it and increasing the
      reference count and only actually free it once the reference count
      reaches zero.
      
      As a side-effect we can now also allow to actually replace the sync
      handler. Previously it was only allowed to clear it after initially
      setting it according to the docs, but the code still allowed to clear it
      and then set a different one.
      
      Fixes #506
      a1c0ca3a
  18. Feb 05, 2020
  19. Jan 09, 2020
Loading