converted the function that destroys lapinfo to the new spec

This commit is contained in:
2026-01-14 20:10:02 +01:00
parent d4a21df8a8
commit c5c5f44ec4

View File

@@ -3,16 +3,10 @@
#include "lapinfo.h" #include "lapinfo.h"
void free_telemetry_info(TelemetryInfo *t) {
free(t->data);
free(t->validity);
// free(t);
}
void destroyLapinfo(LapInfo *info) { void destroyLapinfo(LapInfo *info) {
free_telemetry_info(&info->throttle_pos); free(info->throttle_pos.items);
free_telemetry_info(&info->brake_pos); free(info->brake_pos.items);
free_telemetry_info(&info->steering_pos); free(info->steering_pos.items);
free_telemetry_info(&info->speed); free(info->speed.items);
// free(info); free(info);
} }