Interop: fix minor bug in Indexer

handle empty compiler args
This commit is contained in:
Svyatoslav Scherbina
2016-10-13 16:48:48 +03:00
parent d00d3daf86
commit 2f004edff7
@@ -279,8 +279,10 @@ fun buildNativeIndexImpl(headerFile: File, args: List<String>): NativeIndex {
indexEntityReference.setStatic(null)
}
val commandLineArgs = if (args1.size != 0) mallocNativeArrayOf(Int8Box.Companion, *args1)[0] else null
clang_indexSourceFile(indexAction, clientData, callbacks, IndexerCallbacks.size, 0, headerFile.path,
mallocNativeArrayOf(Int8Box.Companion, *args1)[0], args1.size, null, 0, null, 0)
commandLineArgs, args1.size, null, 0, null, 0)
return res