Use correct index variable for layer2 generator
authorHenning Rogge <henning.rogge@fkie.fraunhofer.de>
Mon, 6 Nov 2017 09:29:20 +0000 (10:29 +0100)
committerHenning Rogge <henning.rogge@fkie.fraunhofer.de>
Mon, 6 Nov 2017 09:29:20 +0000 (10:29 +0100)
src-plugins/generic/layer2_generator/layer2_generator.c

index e79947a..1e38d43 100644 (file)
@@ -230,7 +230,7 @@ _cb_l2gen_event(struct oonf_timer_instance *ptr __attribute((unused))) {
     _set_data(&net->data[net_idx], oonf_layer2_net_metadata_get(net_idx)->type, event_counter);
   }
   for (neigh_idx=0; neigh_idx<OONF_LAYER2_NEIGH_COUNT; neigh_idx++) {
-    _set_data(&net->neighdata[neigh_idx], oonf_layer2_neigh_metadata_get(net_idx)->type, event_counter);
+    _set_data(&net->neighdata[neigh_idx], oonf_layer2_neigh_metadata_get(neigh_idx)->type, event_counter);
   }
 
   if (oonf_layer2_net_commit(net)) {