r295934 - [c-index-test] For the 'core' invocation, avoid running it under a new thread.

Argyrios Kyrtzidis via cfe-commits cfe-commits at lists.llvm.org
Wed Feb 22 21:51:48 PST 2017


Author: akirtzidis
Date: Wed Feb 22 23:51:47 2017
New Revision: 295934

URL: http://llvm.org/viewvc/llvm-project?rev=295934&view=rev
Log:
[c-index-test] For the 'core' invocation, avoid running it under a new thread.

It's unnecessary.

Modified:
    cfe/trunk/tools/c-index-test/c-index-test.c

Modified: cfe/trunk/tools/c-index-test/c-index-test.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/tools/c-index-test/c-index-test.c?rev=295934&r1=295933&r2=295934&view=diff
==============================================================================
--- cfe/trunk/tools/c-index-test/c-index-test.c (original)
+++ cfe/trunk/tools/c-index-test/c-index-test.c Wed Feb 22 23:51:47 2017
@@ -4452,13 +4452,13 @@ int main(int argc, const char **argv) {
   LIBXML_TEST_VERSION
 #endif
 
+  if (argc > 1 && strcmp(argv[1], "core") == 0)
+    return indextest_core_main(argc, argv);
+
   client_data.main_func = cindextest_main;
   client_data.argc = argc;
   client_data.argv = argv;
 
-  if (argc > 1 && strcmp(argv[1], "core") == 0)
-    client_data.main_func = indextest_core_main;
-
   if (getenv("CINDEXTEST_NOTHREADS"))
     return client_data.main_func(client_data.argc, client_data.argv);
 




More information about the cfe-commits mailing list