mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-19 00:01:23 +00:00
gstvalue: Use previous assumption
The types were already checked for equality just before, not need to check for that again Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/453>
This commit is contained in:
parent
9af9113c4a
commit
761bdc9e5c
1 changed files with 2 additions and 4 deletions
|
@ -6042,15 +6042,13 @@ gst_value_can_intersect (const GValue * value1, const GValue * value2)
|
|||
|
||||
if (G_UNLIKELY (GST_VALUE_HOLDS_FLAG_SET (value1) &&
|
||||
GST_VALUE_HOLDS_FLAG_SET (value2))) {
|
||||
GType type1, type2, flagset_type;
|
||||
GType flagset_type;
|
||||
|
||||
type1 = G_VALUE_TYPE (value1);
|
||||
type2 = G_VALUE_TYPE (value2);
|
||||
flagset_type = GST_TYPE_FLAG_SET;
|
||||
|
||||
/* Allow intersection with the generic FlagSet type, on one
|
||||
* side, but not 2 different subtypes - that makes no sense */
|
||||
if (type1 == type2 || type1 == flagset_type || type2 == flagset_type)
|
||||
if (type1 == flagset_type || type2 == flagset_type)
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue