Bugfix/double float promotion warnings (#605)

* Fixed compile warnings from double-float promotions.

* Changed zephyr compile to suppress deprecation warnings

* Fixed CreateObject API return value in many objects header files

* Changed zephyr build defines as strdup is no longer required for log print of strings
This commit is contained in:
Steve Karg
2024-03-26 09:45:01 -05:00
committed by GitHub
parent 1520f2c612
commit 31ffc8024e
25 changed files with 120 additions and 74 deletions
+4 -4
View File
@@ -89,10 +89,10 @@ float linear_interpolate_round(float x1,
y2 = linear_interpolate(x1, x2, x3, y1, y3);
/* round away from zero */
if (y2 > 0.0) {
y2 += 0.5;
} else if (y2 < 0.0) {
y2 -= 0.5;
if (y2 > 0.0f) {
y2 += 0.5f;
} else if (y2 < 0.0f) {
y2 -= 0.5f;
}
return y2;