瀏覽代碼

Use EXIT_FAILURE define instead of hard-coded integers for exit code

Jean-Christophe Fillion-Robin 14 年之前
父節點
當前提交
1fc0df3b07
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      Applications/ctkExampleHostedApp/ctkExampleHostedAppMain.cpp

+ 2 - 2
Applications/ctkExampleHostedApp/ctkExampleHostedAppMain.cpp

@@ -103,7 +103,7 @@ int main(int argv, char** argc)
   catch (const ctkPluginException& exc)
   {
     qCritical() << "Failed to initialize the plug-in framework:" << exc;
-    exit(2);
+    return EXIT_FAILURE;
   }
 
 #ifdef CMAKE_INTDIR
@@ -155,7 +155,7 @@ int main(int argv, char** argc)
     qCritical() << "Could not find plugin.";
     qCritical() << "  Plugin name: " << pluginName;
     qCritical() << "  Plugin path: " << pluginPath;
-    exit(3);
+    return EXIT_FAILURE;
   }
 
   // start the plugin framework