Merge branch 'stable-5.10' into stable-5.11

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

Change-Id: Icd52afc3a74e0d2618181f62515d7e2a8d6c9739
This commit is contained in:
Matthias Sohn 2021-11-28 12:02:45 +01:00
commit 91233eea56
1 changed files with 5 additions and 1 deletions

View File

@ -1529,6 +1529,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$
@ -1551,7 +1552,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) {