This allows validate to clean up before the 'leak' tracer list leaked
objects.
Reviewed-by: Thibault Saunier <tsaunier@gnome.org>
Differential Revision: https://phabricator.freedesktop.org/D1231
Pads returned using the playbin get-{audio,video}-pad are reffed.
Reviewed-by: Thibault Saunier <tsaunier@gnome.org>
Differential Revision: https://phabricator.freedesktop.org/D1027
My patch fixing monitor leak (15e7f1bbfd)
introduced a ref cycle between GstValidateReporter and
GstValidateReport.
The reports uses its reporter so it needs a ref on it
to ensure it's stay alive. But reports are owned by GstValidateReporter and/or
GstValidateRunner.
The best way I found to break this cycle is to introduce this purge
method. It's not great but the design is a bit tricky.
Reviewed-by: Thibault Saunier <tsaunier@gnome.org>
Differential Revision: https://phabricator.freedesktop.org/D1029
A GHashTableIter is invalided if the hash table is modified while we are
iterating. Prevent this by taking the runner lock.
Fix assertion warnings with
validate.file.transcode.to_vorbis_and_vp8_in_webm.Sintel_2010_720p_mkv_srt
Reviewed-by: Thibault Saunier <tsaunier@gnome.org>
Differential Revision: https://phabricator.freedesktop.org/D1026
Add to deploy setup_sink_props_max_lateness scenario.
When running gst-validate with valgrind option on the installed package, it fails to find that scenario.
Reviewed-by: Guillaume Desmottes <guillaume.desmottes@collabora.co.uk>
Reviewed-by: Thibault Saunier <tsaunier@gnome.org>
Differential Revision: https://phabricator.freedesktop.org/D379
Only expect fully identical stream-id from URI which are not local files
nor from our local http server.
Fixes issues with non-default http server port
When doing a track switch, the only reliable way to detect that it
happened is whether a new STREAM_START arrives.
Relying on a DISCONT buffer is not satisfactory, since there might
not have been an element setting that flag upstream.
Checking whether the first buffer after a STREAM_START has the
DISCONT flag properly set should be done in parallel
gst-validate-scenario.c:183:7: error: '_gst_validate_action_type' redeclared without dllimport attribute: previous dllimport ignore
This is also declared in gst-validate-internal.h
As this is what user will expect in this case.
For example with this scenario:
set-state, state=null; playback-time=5
set-property, target-element-name=dvbsrc0, property-name=delsys, property-value=11
play;
Instead of providing full absolute path while validating the file, should be
able to provide the relative path with respect to the present directory.
https://bugzilla.gnome.org/show_bug.cgi?id=753494
The monitor returned by gst_validate_monitor_factory_create() was never
unreffed.
Report instances now have to keep a ref, as suggested by the TODO, as
the reporter is no longer leaked.
Reviewed-by: Thibault Saunier <tsaunier@gnome.org>
Differential Revision: https://phabricator.freedesktop.org/D1012
The gstvalidate_debug may not be initialized like with the
validate/reporting which was crashing when run with GST_DEBUG=5.
Reviewed-by: Thibault Saunier <tsaunier@gnome.org>
Differential Revision: https://phabricator.freedesktop.org/D1004
The 'all_raw_caps' list is never used and was just leaking caps.
Reviewed-by: Thibault Saunier <tsaunier@gnome.org>
Differential Revision: https://phabricator.freedesktop.org/D979
- the pad returned by gst_element_get_static_pad() was leaked.
- unref the pad from snode when updating it, not the pad passed as
callback to pad_added_cb()
Reviewed-by: Thibault Saunier <tsaunier@gnome.org>
Differential Revision: https://phabricator.freedesktop.org/D958
_add_override_from_struct() could, in theory, register more than once
the same override so we should not transfer the ref.
Reviewed-by: Thibault Saunier <tsaunier@gnome.org>
Differential Revision: https://phabricator.freedesktop.org/D956
Makes fixing easier as then we can just re-use the generated trace.
Reviewed-by: Thibault Saunier <tsaunier@gnome.org>
Differential Revision: https://phabricator.freedesktop.org/D953
* Some SEGMENT might be updates caused by calling gst_pad_set_offset(),
which will send the same segment but with an updated offset and/or
based field. For those segments, we don't require a DISCONT on the
following buffer.
* Ignore differences in flags, they aren't relevant for now to figure
out whether the segment is an update or not
* Ignore difference in 'position', it's only meant for internal usage
by elements.
* Changes in the end position (stop in forward playback and start in
reverse playback) are considering updates
Furthermore, also expect a DISCONT flag on the first buffer following
a STREAM_START.
When a first testsuite will set paths, it does not mean that we should
just register following testsuite test manager default tests.
So we need to make a difference between the media paths the user passed
with --media-path and the ones defined by the testsuite.
After a seek we need to wait for the right segment (meaning the segment
with seqnum == last seek/flush stop seqnum) to check whether the segment.time
has been properly set.
In the case and element is in READY or is going to READY state, it can
always return GST_FLOW_FLUSHING.
Avoid a race where a demuxer sinkpad has not been set to FLUSHING when we are
still processing a buffer but downstream is already FLUSHING and thus
the demuxer is already returning FLUSHING.
MAX(0, ((gint64) priv->segment_start - priv->seek_pos_tol) will be a high
positive number thanks to being interpreted as unsigned values if
segment_start < seek_pos_tol. Fix this by explicitly checking for this case
and only doing the subtraction otherwise.
This fixes the problem from fdccffbb2e
completely now.
https://bugzilla.gnome.org/show_bug.cgi?id=763602
When listing tests, checking whether uri is present or not and displaying error.
But uri does notneed to be present in case of pipeline generator. So the condition check is wrong.
This results in validateelements testsuite not working. Hence modifying the condition to
not error out on valid cases.
https://bugzilla.gnome.org/show_bug.cgi?id=762422
This way we do not need the LD_PRELOAD hack anymore
Add a new libgstvalidateplugin GStreamer plugin, making sure it shares
the exact same code as the library (exposing only the wanted symbols).
Fix the way we set where to install GstValidate plugins
Try to keep backward compatibility even if tracers should never be instantiated
after an GstElement has been instantiated.
Differential Revision: https://phabricator.freedesktop.org/D459
The seekable variable in media_info file is of type string. When checking if the file
is seekable using is_seekable, it just returns the string, resulting in it always being true.
It should actually be comparing the string and returning true or false based on comparison
https://bugzilla.gnome.org/show_bug.cgi?id=755854
In case of fast-forward scenario, the playback-time is not set properly
as per increase in the rate. This is resulting in short media files of duration
less that 15 seconds to fail.
https://bugzilla.gnome.org/show_bug.cgi?id=754151
This ensures our sink pad event wrapper is properly called if the
element implement a GstPadEventFullFunc instead of a regular one.
Removes all stray "buffer received before segment" issues with
queue/multiqueue
Use fake elements instead of real ones in our tests so that
we control exactly the number of issues generated.
Until now we were trying to hide extra issues with a probe dropping
events and buffers but since 2dfa548f36
"pad: Append hooks instead of prepending to call them in the order they were added"
in core, hidding will not work.
PTS and DTS can be deceiving as a change in segment can dramatically change
playback synchronization. Track the running-time as well to properly
get any change in synchronization
Having a default value of 0 meant that a g_idle_add loop was constantly
running, causing each test to use 100% cpu.
This is no longer required. Using a 10ms interval brings down cpu usage
to a sane value
When a file does not contain any stream info, then there is no need
to create the media info file as, it is not considered to be a valid file
and no validate checks are done for the same.
This skips unnecessary files like .txt, .dump files
https://bugzilla.gnome.org/show_bug.cgi?id=754006
When there are no media-info files present and --generate-media-info
option is not given, then it just fails without printing error.
Printing an error stating, use --generate-media-info if there are no
media info files.
When there are neither media files and media info files, print error
stating the same
https://bugzilla.gnome.org/show_bug.cgi?id=755087
When g_option_context_parse fails, context and error variables are not getting free'd
which results in memory leaks. Free'ing the same.
And replacing g_error_free with g_clear_error, which checks if the error being passed
is not NULL and sets the variable to NULL on free'ing.
https://bugzilla.gnome.org/show_bug.cgi?id=753862
The user might have scenarios specific to a particular pipeline, and the
application might have several pipelines running and scenarios that
apply on specific pipeline. We have to handle that valid use case.
Summary:
Move variable declarations in the for block so we won't try re-free
tldir in case of early short circuiting of the 'for' code.
Depends on D348
Reviewers: thiblahute
Reviewed By: thiblahute
Differential Revision: https://phabricator.freedesktop.org/D349
Summary:
We were checking if the path was a full one but was using the
scenario_name instead of this path when trying to load the scenario.
Depends on D346
Reviewers: thiblahute
Reviewed By: thiblahute
Differential Revision: https://phabricator.freedesktop.org/D348
errors-for-leak-kinds should be set to definite, because almost every test case
, will have possibly lost memory, which may or may not be a leak.
And throwing error for all these cases doesn't seem to be correct.
https://bugzilla.gnome.org/show_bug.cgi?id=752754
When creating the class names for media check, uri is being used,
instead of the path. Hence converting the uri using uri2path and creating
class name.
Add double quotes for valgrind logs, to support special characters like space
https://bugzilla.gnome.org/show_bug.cgi?id=752808
writer_new_discover() API should be able to accept NULL GError and in case of
error, if GError is passed on as parameter, it should be propagated, else it
should be free'd.
https://bugzilla.gnome.org/show_bug.cgi?id=753340
When file name consists of characters from other languages, say korean,
then it throws an error
Error initializing: Invalid byte sequence in conversion input
Hence setting locale to all to fix this.
And changing the media-info argument to type G_OPTION_ARG_FILENAME
https://bugzilla.gnome.org/show_bug.cgi?id=753486
Even though relative paths are supported, right now it does not
work when we give the path as 'media/' present in the current directory.
Adding support for the same.
https://bugzilla.gnome.org/show_bug.cgi?id=754100
As soon as the track is changed, the pipeline state is set to NULL
by execution 'stop' action even if there is a 'playback-time' with 5sec.
If the AV sink is not synchronized,
audio fakesink and video fakesink has different position value.
When the validate request the position information of pipeline
to do 'stop' action, the audio fakesink response of the position query
with the bigger value than 5sec.
https://bugzilla.gnome.org/show_bug.cgi?id=755101
If the scenario handles the states and wants to stay in PAUSED, it's not a
good idea to change the state to PLAYING when receiving BUFFERING=100%. This
caused a race condition in varios seeking tests, most often in the dash scrub
seeking test.
If the scenario handles the states and wants to stay in PAUSED, it's not a
good idea to change the state to PLAYING when receiving BUFFERING=100%. This
caused a race condition in varios seeking tests, most often in the dash scrub
seeking test.
When message_async is not called during error cases, needs_parsing GList is
not being freed resulting in leak. Hence free'ing the same in finalize.
https://bugzilla.gnome.org/show_bug.cgi?id=753339
There is no check to see if stream info is available. This leads to
assertion error. Adding proper error messages for the same and reported
the same as a validate warning message.
https://bugzilla.gnome.org/show_bug.cgi?id=752758
When discovering the files, there will be different kind of errors. If we print
the exact message, then it will be more helpful for user. Especially in the case
of missing plugins, displaying which plugin is missing as error message
https://bugzilla.gnome.org/show_bug.cgi?id=752758