Verify compatibility before parsing config message

This adds a verion field to the ubus configuration message, to avoid
acting upon a message from an incompatible version of dawn.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
This commit is contained in:
Eneas U de Queiroz 2021-08-05 10:55:51 -03:00 committed by Polynomdivision
parent a7a830950a
commit 1e34357bdc
3 changed files with 15 additions and 0 deletions

View file

@ -52,6 +52,11 @@ void mac_array_delete(struct mac_entry_s* entry);
// ---------------- Global variables ----------------
/*** Metrics and configuration data ***/
// TODO: Define a proper version string
#ifndef DAWN_CONFIG_VERSION
#define DAWN_CONFIG_VERSION "1"
#endif
// ---------------- Structs ----------------
struct probe_metric_s {
int ap_weight; // TODO: Never evaluated?