XML-API
XML-API copied to clipboard
sysvarlist.cgi Retrieve min/max values only when sysvar is numeric
min and max values are only requested if ValueType = 4 (numeric). This prevents Rega Log Entries "metadata property 'MIN' does not exist" and "metadata property 'MAX' does not exist" for every nonnumeric sysvar every time sysvarlist.cgi is called.
Fixes Issue #45
Thanks for the PR. However, two things remain:
- The log entries in /var/log/messages caused by ReGaHss are pure
INFO
entries, thus you can simply ignore them. - How about the other value types? You just catch value type 4 which in fact is ivtFloat. But how sure are you that there are not other Value Types you have to catch?
ad 1) that's correct. It's simply a matter of calling functions that we know will fail, so we could save cpu per not doing so ad 2) at least the web interface offers only one datatype for sysvars with a min/max entry. But maybe there are other types of sysvars which are created elsewhere. I do not have enough insight and knowledge to give a definitive answer.