This version of Unity is unsupported.

CanvasRenderer.SetMesh

Switch to Manual
public void SetMesh(Mesh mesh);

Description

Sets the Mesh used by this renderer. Note the Mesh must be read/write enabled.