battery_statefs.c:95:8: warning: initializing 'char *' with an expression of type 'const char [38]' discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
{STATEFS_ROOT "Current", "current", NULL, 1e-6}, // from uA to A
^~~~~~~~~~~~~~~~~~~~~~
}
struct {
- char *path;
- char *type;
- char *type_instance;
+ const char *path;
+ const char *type;
+ const char *type_instance;
gauge_t factor;
} metrics[] = {
{STATEFS_ROOT "Current", "current", NULL, 1e-6}, // from uA to A