Changeset 161074e in OpenModelica
- Timestamp:
- 2020-09-24T14:23:19+02:00 (4 years ago)
- Branches:
- Added-citation-metadata, maintenance/v1.17, maintenance/v1.18, maintenance/v1.19, maintenance/v1.20, maintenance/v1.21, maintenance/v1.22, maintenance/v1.23, master, omlib-staging
- Children:
- 3152688, ef9d6fcf
- Parents:
- 76de683
- git-author:
- Adeel Asghar <adeel.asghar@…> (09/23/20 17:37:39)
- git-committer:
- Adeel Asghar <adeel.asghar@…> (09/24/20 14:23:19)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
OMCompiler/SimulationRuntime/c/simulation/simulation_runtime.cpp
rdbb0b7ae r161074e 788 788 initDumpSystem(); 789 789 790 if(setLogFormat(argc, argv) || helpFlagSet(argc, argv) || checkCommandLineArguments(argc, argv)) 790 int checkArgumentsRes = checkCommandLineArguments(argc, argv); 791 792 #ifndef NO_INTERACTIVE_DEPENDENCY 793 if(omc_flag[FLAG_PORT]) { 794 std::istringstream stream(omc_flagValue[FLAG_PORT]); 795 int port; 796 stream >> port; 797 sim_communication_port_open = 1; 798 sim_communication_port_open &= sim_communication_port.create(); 799 sim_communication_port_open &= sim_communication_port.connect("127.0.0.1", port); 800 } 801 #endif 802 803 int logFormatResult = setLogFormat(argc, argv); 804 805 #ifndef NO_INTERACTIVE_DEPENDENCY 806 if (isXMLTCP && !sim_communication_port_open) { 807 errorStreamPrint(LOG_STDOUT, 0, "xmltcp log format requires a TCP-port to be passed (and successfully open)"); 808 EXIT(1); 809 } 810 #endif 811 812 if(logFormatResult || helpFlagSet(argc, argv) || checkArgumentsRes) 791 813 { 792 814 infoStreamPrint(LOG_STDOUT, 1, "usage: %s", argv[0]); … … 1059 1081 #ifndef NO_INTERACTIVE_DEPENDENCY 1060 1082 if(omc_flag[FLAG_PORT]) { 1061 std::istringstream stream(omc_flagValue[FLAG_PORT]);1062 int port;1063 stream >> port;1064 sim_communication_port_open = 1;1065 sim_communication_port_open &= sim_communication_port.create();1066 sim_communication_port_open &= sim_communication_port.connect("127.0.0.1", port);1067 1068 1083 if(0 != strcmp("ia", data->simulationInfo->outputFormat)) { 1069 1084 communicateStatus("Starting", 0.0, data->simulationInfo->startTime, 0); 1070 1085 } 1071 }1072 1073 if (isXMLTCP && !sim_communication_port_open) {1074 errorStreamPrint(LOG_STDOUT, 0, "xmltcp log format requires a TCP-port to be passed (and successfully open)");1075 EXIT(1);1076 1086 } 1077 1087 #endif
Note: See TracChangeset
for help on using the changeset viewer.