WebCamTexture.Play() Missing Profiler.EndSample

Hi Unity Team and Community,

While working with Unity Version 6000.0.34f1, calling WebCamTexture.Play(); triggers the following error:

Missing Profiler.EndSample (Every BeginSample call must have a subsequent EndSample call within the same frame): Gfx.UploadTexture
Previous 5 samples:
	Gfx.UploadTexture
	RenderLoop
	Semaphore.WaitForSignal
	Gfx.WaitForGfxCommandsFromMainThread
	CustomRenderTextures.Update
In the scope:
	Gfx.UploadTexture
	RenderLoop
	<Root>

Steps to Reproduce:

  1. Create a new Unity project in version 6000.0.34f1.
  2. Add a script to a GameObject that initializes and starts a WebCamTexture:
using UnityEngine;
using UnityEngine.UI;

public class EasyCamera : MonoBehaviour
{
    [SerializeField] private RawImage m_Image = default;
    private WebCamTexture m_WebCamTexture = null;

    // Start is called once before the first execution of Update after the MonoBehaviour is created
    void Start()
    {
        m_WebCamTexture = new WebCamTexture();
        m_WebCamTexture.Play();
    }
}

Thank you for your time and consideration.

We see it in 6000.0.28f1, as well. Looks like it’s fixed in 6000.0.35f1:
Unity Issue Tracker - Profiler related errors are thrown when WebCamTexture is played in the Player