aboutsummaryrefslogtreecommitdiff
path: root/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'util.c')
-rw-r--r--util.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/util.c b/util.c
index bd3f71f..d78809f 100644
--- a/util.c
+++ b/util.c
@@ -5,13 +5,13 @@
float pressure_to_metres_asl(float real, float setting)
{
- return 44330.f*(1.f-pow(real/setting, 1/5.255));
+ return 44330.f*(1.f-powf(real/setting, 1/5.255));
}
void blank_to_eol(char *line, size_t len)
{
size_t i = 0;
- for (i = strlen(line); i < len - 1; i++) {
+ for (i = strnlen(line, len - 1); i < len - 1; i++) {
line[i] = ' ';
}
line[i] = '\0';