Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix two output conversion errors (#378)
* icepack_itd: fix format string length causing "output conversion error" With kcatbound = -1 (single category run) (or kcatbound = 2), hin_max(n) is 100 (or 999), which is one character too long for the format specification '(f6.3)' used to output it in icepack_init_itd_hist. This leads to an "output conversion error" (Intel Fortran runtime error code 63, [1]), which is usually not fatal. However, this error becomes fatal if FOR_DUMP_CORE_FILE [2] is defined in the environment, which is necessary on some platforms to get core dumps from a crashing program. Note that this interaction is *not* mentioned in the Intel documentation. Increase the format specifier by one digit to avoid this error. For consistency, also increase it for 'hin_max(n-1)'. [1] https://www.intel.com/content/www/us/en/develop/documentation/fortran-compiler-oneapi-dev-guide-and-reference/top/compiler-reference/error-handling/handling-run-time-errors/list-of-run-time-error-messages.html [2] https://www.intel.com/content/www/us/en/develop/documentation/fortran-compiler-oneapi-dev-guide-and-reference/top/compilation/supported-environment-variables.html#supported-environment-variables_GUID-D3C9AA20-CD90-4833-8B90-AB971E7B90B1 * icepack_fsd: fix format string length causing "output conversion error" If floe_rad(n) or floe_rad(n-1) is greater or equal to 100, writing it to c_fsd[12] with the format specifier '(f6.3)' causes an "output conversion error" when compiling with the Intel compiler, as the format spec is one digit short. This is not ideal for reasons detailed in the previous commit. Bump the format spec by one digit to avoid that error.
- Loading branch information