Fix crash when color input index mapping is nullptr

In this case, the mapping is expected to implicitly be identity.

Bug: angleproject:352364582
Test: dEQP-VK.dynamic_rendering.primary_cmd_buff.local_read.*
Change-Id: I5b687daf6571d11c751cadd7f22c3e6278ad9465
Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/74308
Presubmit-Ready: Shahbaz Youssefi <syoussefi@google.com>
Kokoro-Result: kokoro <noreply+kokoro@google.com>
Commit-Queue: Shahbaz Youssefi <syoussefi@google.com>
Reviewed-by: Chris Forbes <chrisforbes@google.com>
Tested-by: Shahbaz Youssefi <syoussefi@google.com>
diff --git a/src/Pipeline/SpirvShader.cpp b/src/Pipeline/SpirvShader.cpp
index 7390bde..7dc5804 100644
--- a/src/Pipeline/SpirvShader.cpp
+++ b/src/Pipeline/SpirvShader.cpp
@@ -1862,7 +1862,7 @@
 	{
 		for(auto i = 0u; i < inputAttachmentMapping->colorAttachmentCount; i++)
 		{
-			auto inputIndex = inputAttachmentMapping->pColorAttachmentInputIndices[i];
+			auto inputIndex = inputAttachmentMapping->pColorAttachmentInputIndices != nullptr ? inputAttachmentMapping->pColorAttachmentInputIndices[i] : i;
 			if(inputIndex != VK_ATTACHMENT_UNUSED)
 			{
 				inputIndexToColorIndex[inputIndex] = i;