LibClang unsaved file Crashing Windows

I am using libclang 3.5 and I am calling clang_ReparseTranslationUnit.

It works if the array of unsaved files is length 0 or 1, but if the array is 2 or more in length I get:

I am calling this function from .NET. Can anyone assist me in working out what is causing this error?

Much appreciated


The error message is as follows:

“Assertion failed!”

Program… libclang.dll File: stringRef.g Line 77,
Expression Str && “StringRef cannot be built from a NULL argument”.