diff --git a/CHANGELOG.md b/CHANGELOG.md index 262fe86796..d76a381ddc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ All notable changes to the Zowe Installer will be documented in this file. ## `2.18.1` +- Bugfix: When `--log-dir` parameter for `zwe` command is a file, there might be an error "InternalError: stack overflow". [#40nn](https://github.com/zowe/zowe-install-packaging/pull/40nn) - Bugfix: Error message `ZWEL0141E` did not print user ID. [#3971](https://github.com/zowe/zowe-install-packaging/pull/3971) ## `2.17.0` diff --git a/bin/libs/logging.sh b/bin/libs/logging.sh index 6e41778aca..787c4fe7a4 100755 --- a/bin/libs/logging.sh +++ b/bin/libs/logging.sh @@ -14,6 +14,9 @@ export ZWE_PRIVATE_LOG_FILE= prepare_log_file() { + if [ -f "${1}" ]; then + print_error_and_exit "Error ZWEL0102E: Invalid parameter --log-dir=${1} (not a directory)" "" 102 + fi # use absolute path to make sure we can always write to correct location even # if other scripts changed current working directory log_dir=$(convert_to_absolute_path "${1}" | remove_trailing_slash)