Skip to content

Commit

Permalink
Porting #5254 - some snmp values wrong in poller cache
Browse files Browse the repository at this point in the history
Created a data source template to specify the snmp port, but it doesn't seem to work properly
  • Loading branch information
TheWitness committed Apr 1, 2023
1 parent 5c46287 commit 7f1382f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG
Expand Up @@ -58,6 +58,7 @@ Cacti CHANGELOG
-feature: Upgrade d3.js to version 7.8.2

1.2.25
-issue#5254: Created a data source template to specify the snmp port, but it doesn't seem to work properly
-issue#5275: Boost stats can display odd values when running
-issue#5277: Boost should not attempt to start if there are no poller_output_boost records
-issue#5279: Rebuild poller cache does not work as expected
Expand Down
5 changes: 4 additions & 1 deletion lib/utility.php
Expand Up @@ -769,7 +769,10 @@ function push_out_host($host_id, $local_data_id = 0, $data_template_id = 0) {
$field = 'id';
}

if (preg_match('/^' . VALID_HOST_FIELDS . '$/i', $template_field['type_code']) && $template_field['t_value'] != 'on') {
// Only override if the template value is null at this point
if (preg_match('/^' . VALID_HOST_FIELDS . '$/i', $template_field['type_code']) &&
$template_field['t_value'] != 'on' && $template_field['value'] == '') {

// It's a valid host type-code
$update = true;

Expand Down

0 comments on commit 7f1382f

Please sign in to comment.