mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-26 19:29:16 +00:00
LibWeb: Validate AudioParam context in AudioNode::connect()
An exception is now thown if an `AudioNode` attempts to connect to an `AudioParam` from a different `BaseAudioContext`.
This commit is contained in:
committed by
Tim Ledbetter
parent
2edd0812ca
commit
5c57acf140
@@ -41,7 +41,7 @@ WebIDL::ExceptionOr<GC::Ref<GainNode>> GainNode::construct_impl(JS::Realm& realm
|
||||
|
||||
GainNode::GainNode(JS::Realm& realm, GC::Ref<BaseAudioContext> context, GainOptions const& options)
|
||||
: AudioNode(realm, context)
|
||||
, m_gain(AudioParam::create(realm, options.gain, NumericLimits<float>::lowest(), NumericLimits<float>::max(), Bindings::AutomationRate::ARate))
|
||||
, m_gain(AudioParam::create(realm, context, options.gain, NumericLimits<float>::lowest(), NumericLimits<float>::max(), Bindings::AutomationRate::ARate))
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user