mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
NPE in HgShowConfigCommand: result of HgCommandService.execute may be null. [Reviewed by Maxim Shafirov]
This commit is contained in:
@@ -40,6 +40,10 @@ public class HgShowConfigCommand {
|
||||
HgCommandResult result =
|
||||
HgCommandService.getInstance(project).execute(repo, "showconfig", null);
|
||||
|
||||
if (result == null) {
|
||||
return Collections.emptyMap();
|
||||
}
|
||||
|
||||
Map<String, String> options = new HashMap<String, String>();
|
||||
for (String line : result.getOutputLines()) {
|
||||
String[] option = StringUtils.splitPreserveAllTokens(line, '=');
|
||||
|
||||
Reference in New Issue
Block a user