<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>226641</bug_id>
          
          <creation_ts>2021-06-04 05:26:34 -0700</creation_ts>
          <short_desc>CountQueuingStrategy.constructor misses checking if the init.highWaterMark is exist or not</short_desc>
          <delta_ts>2021-06-11 05:27:19 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>WebCore Misc.</component>
          <version>WebKit Local Build</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>NEW</bug_status>
          <resolution></resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="zyscoder@gmail.com">zyscoder</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>bugs-noreply</cc>
    
    <cc>calvaris</cc>
    
    <cc>cdumez</cc>
    
    <cc>mcatanzaro</cc>
    
    <cc>sam</cc>
    
    <cc>webkit-bug-importer</cc>
    
    <cc>youennf</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1766742</commentid>
    <comment_count>0</comment_count>
    <who name="zyscoder@gmail.com">zyscoder</who>
    <bug_when>2021-06-04 05:26:34 -0700</bug_when>
    <thetext>Steps to reproduce:

(1) Open a tab and navigate to any URL;
(2) Run one of the following codes in the Console of Devtools:
```
new CountQueuingStrategy({highWaterMark:undefined}) / new CountQueuingStrategy({})
```
(3) Then this code would be evaluated successfully without throwing any exception.

Actual results:

This code is evaluated successfully without throwing any exception.

Expected results:

As the spec(https://streams.spec.whatwg.org/#dictdef-queuingstrategyinit) says, CountQueuingStrategy.constructor asks a double value as its init.highWaterMark param. Thus these codes should throw an exception.

In my test, both Chrome and Firefox throw exceptions:
Chrome: `VM1491:1 Uncaught TypeError: Failed to construct &apos;CountQueuingStrategy&apos;: required member highWaterMark is undefined.`
Firefox: `Uncaught TypeError: &apos;highWaterMark&apos; must not be undefined`</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1768912</commentid>
    <comment_count>1</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2021-06-11 05:27:19 -0700</bug_when>
    <thetext>&lt;rdar://problem/79193758&gt;</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>