Merge branch 'stable-5.9' into stable-5.10

* stable-5.9:
  FS: debug logging only if system config file cannot be found

Change-Id: Ib9eb4f4cc44ecc1958c9b6455ab7865913f8b247
This commit is contained in:
Matthias Sohn 2021-11-28 12:02:03 +01:00
commit 684ec2c316
1 changed files with 5 additions and 1 deletions

View File

@ -1524,6 +1524,7 @@ protected File discoverGitSystemConfig() {
String w;
try {
// This command prints the path even if it doesn't exist
w = readPipe(gitExe.getParentFile(),
new String[] { gitExe.getPath(), "config", "--system", //$NON-NLS-1$ //$NON-NLS-2$
"--edit" }, //$NON-NLS-1$
@ -1546,7 +1547,10 @@ protected File discoverGitSystemConfig() {
"--show-origin", "--list", "-z" }, //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
Charset.defaultCharset().name());
} catch (CommandFailedException e) {
LOG.warn(e.getMessage());
// This command fails if the system config doesn't exist
if (LOG.isDebugEnabled()) {
LOG.debug(e.getMessage());
}
return null;
}
if (w == null) {