mirror of https://gerrit.osmocom.org/libosmocore
stats: don't try to save unknown stats reporter types
The point of having a public API to register further stats reporters is to enable applications or other libraries to do so. As we in libosmocore don't know anything about the parameters of such a stats reporter, don't try to do a partial save of them when saving the config file. Change-Id: I2986313375daec1c4959a6a914e3fb2980a5d7ca
This commit is contained in:
parent
e8e24c7be9
commit
8f25fd27ed
|
@ -671,6 +671,11 @@ static int config_write_stats_reporter(struct vty *vty, struct osmo_stats_report
|
|||
case OSMO_STATS_REPORTER_LOG:
|
||||
type = "log";
|
||||
break;
|
||||
default:
|
||||
/* don't try to save unknown stats reporters to the VTY. Imagine some
|
||||
* application registering a new application specific stats reporter that
|
||||
* this VTY code knows nothing about! */
|
||||
return 0;
|
||||
}
|
||||
|
||||
vty_out(vty, "stats reporter %s", type);
|
||||
|
|
Loading…
Reference in New Issue