SetTexture Not Working

After upgrading from Unity 5.1.1f1 to 5.3.1f1, I have a feature in my game using SetTexture/ RenderTexture which no longer works. I have a build of the game running on a separate laptop using 5.1.1f1 which still works correctly. The code looks like this:

m_ScreenShot = CaptureScreen();
m_ScreenCapMat.SetTexture( 0, (Texture)m_ScreenShot);

The CaptureScreen function consists of this:

RenderTexture CaptureScreen() {
		Camera screen_cap = m_ScreenShotCam.GetComponent<Camera>();
		screen_cap.enabled = true;
		RenderTexture rt = new RenderTexture( screen_cap.pixelWidth, screen_cap.pixelHeight, 24 /*depth*/);
		screen_cap.targetTexture = rt;
		screen_cap.enabled = false;
		return rt;

Do I need to update something to get this working in 5.3.1f1?

@Esperento I just came across this same problem. What fixed it for me was referring to the texture by id and not index. So instead of SetTexture(0, MyTexture) try SetTexture(“_MainTex”, MyTexture). Or depending on your shader, the main texture could be named something else.
At any rate, setting a texture by index doesn’t seem to work any more. The function is still there, though, so I wonder if this is a bug.