From e006899bc1480a5d8ea0dfbb907346d16523ca43 Mon Sep 17 00:00:00 2001 From: "Christian W. Zuckschwerdt" Date: Tue, 9 Feb 2016 20:19:40 +0100 Subject: [PATCH] also switch the labels on output conversion --- src/rtl_433.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/rtl_433.c b/src/rtl_433.c index 22c1030d..ed8a6a29 100644 --- a/src/rtl_433.c +++ b/src/rtl_433.c @@ -212,6 +212,7 @@ void data_acquired_handler(data_t *data) if ((d->type == DATA_DOUBLE) && !strcmp(d->key, "temperature_F")) { *(double*)d->value = fahrenheit2celsius(*(double*)d->value); + d->key = strdup("temperature_C"); char *pos; if (d->format && (pos = strrchr(d->format, 'F'))) { @@ -225,6 +226,7 @@ void data_acquired_handler(data_t *data) if ((d->type == DATA_DOUBLE) && !strcmp(d->key, "temperature_C")) { *(double*)d->value = celsius2fahrenheit(*(double*)d->value); + d->key = strdup("temperature_F"); char *pos; if (d->format && (pos = strrchr(d->format, 'C'))) {