<?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>178218</bug_id>
          
          <creation_ts>2017-10-12 10:20:48 -0700</creation_ts>
          <short_desc>getUserMedia video track &quot;ended&quot; on first load of new tab</short_desc>
          <delta_ts>2017-10-18 10:51:26 -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>WebRTC</component>
          <version>Safari 11</version>
          <rep_platform>iPhone / iPad</rep_platform>
          <op_sys>iOS 11</op_sys>
          <bug_status>NEW</bug_status>
          <resolution></resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Mike Block">mikeblock</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>eric.carlson</cc>
    
    <cc>youennf</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1359625</commentid>
    <comment_count>0</comment_count>
    <who name="Mike Block">mikeblock</who>
    <bug_when>2017-10-12 10:20:48 -0700</bug_when>
    <thetext>The video track in the stream reports as readyState=&quot;ended&quot; on gUM return. Not sure if this is a load sequence error. If I reload the page though it works reliably, both audio and video active.

Steps to reproduce:

1. call a page in a new tab
2. add navigator.mediaDevices.getUserMedia with {audio:true,video:{facingMode:&apos;user&apos;}} call to a window.onload event
3. check the readystate of the returned tracks - video is shown as &quot;ended&quot;
4. reload the tab and everything is fine

I&apos;ve also tried adding an alert before the getUserMedia call to see if there&apos;s a background event that needs to complete. No amount of waiting changes the result and there are no errors reported in console.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1361779</commentid>
    <comment_count>1</comment_count>
    <who name="youenn fablet">youennf</who>
    <bug_when>2017-10-18 10:51:26 -0700</bug_when>
    <thetext>Fippo mentioned in https://github.com/webrtc/adapter/issues/699 the following information:
------------
  you might want to check https://bugs.chromium.org/p/chromium/issues/detail?id=574041 -- I get the code responsible is old enough to be still shared with webkit.

------------</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>