Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Eclipse Projects
Eclipse Titan
titan.EclipsePlug-ins
Commits
a49fbb54
Commit
a49fbb54
authored
Feb 03, 2021
by
Gergo Ujhelyi
Browse files
fix null pointer when config file missing
parent
1466e6e0
Changes
2
Hide whitespace changes
Inline
Side-by-side
org.eclipse.titan.runtime/src/org/eclipse/titan/runtime/core/mctr/Cli.java
View file @
a49fbb54
...
...
@@ -140,6 +140,11 @@ public class Cli extends UserInterface {
System
.
out
.
printf
(
"Using configuration file: %s\n"
,
config_file
.
getName
());
final
CfgAnalyzer
cfgAnalyzer
=
new
CfgAnalyzer
();
if
(
config_file
==
null
)
{
System
.
out
.
println
(
"Error was found in the configuration file. Exiting"
);
cleanUp
();
return
EXIT_FAILURE
;
}
final
boolean
config_file_failure
=
cfgAnalyzer
.
parse
(
config_file
);
if
(
config_file_failure
)
{
System
.
out
.
println
(
"Error was found in the configuration file. Exiting"
);
...
...
org.eclipse.titan.runtime/src/org/eclipse/titan/runtime/core/mctr/ConfigData.java
View file @
a49fbb54
...
...
@@ -140,6 +140,9 @@ public class ConfigData {
//Package-private
static
String
getConfigFileContent
(
File
config_file
)
{
if
(
config_file
==
null
)
{
return
""
;
}
StringBuilder
contentBuilder
=
new
StringBuilder
();
BufferedReader
br
=
null
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment