Fixed potential null reference exception in the c# parser.