diff --git a/libs/libm/libm/lib_log.c b/libs/libm/libm/lib_log.c index 9b8e23b97d..5bf3c67948 100644 --- a/libs/libm/libm/lib_log.c +++ b/libs/libm/libm/lib_log.c @@ -98,7 +98,7 @@ double log(double x) iter = 0; } - if (relax_factor > 1.0) + if (iter == 0) { epsilon *= relax_factor; } diff --git a/libs/libm/libm/lib_logf.c b/libs/libm/libm/lib_logf.c index 35672915b4..3cf050bca0 100644 --- a/libs/libm/libm/lib_logf.c +++ b/libs/libm/libm/lib_logf.c @@ -94,7 +94,7 @@ float logf(float x) iter = 0; } - if (relax_factor > 1.0F) + if (iter == 0) { epsilon *= relax_factor; }