Skip to content

Commit 01aea42

Browse files
committed
Fix typos
1 parent 1b73c92 commit 01aea42

9 files changed

Lines changed: 11 additions & 16 deletions

File tree

src/collector/metric.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,5 +79,5 @@ void UpdateMetric(char *ident, uint32_t exporterID, EXgenericFlow_t *genericFlow
7979

8080
void *MetricThread(void *arg);
8181

82-
#define MetricExpporterID(r) (((uint32_t)(r)->exporterID << 16UL) | ((uint32_t)(r)->engineType << 8UL) | (uint32_t)(r)->engineID)
82+
#define MetricExporterID(r) (((uint32_t)(r)->exporterID << 16UL) | ((uint32_t)(r)->engineType << 8UL) | (uint32_t)(r)->engineID)
8383
#endif

src/libnffile/nffileV2.h

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,9 @@
5050
*
5151
* Principal layout, recognized as LAYOUT_VERSION_2:
5252
*
53-
* +-----------+-------------+-------------+-------------+-----+-------------+
54-
* |Fileheader | datablock 0 | datablock 1 | datablock 2 | ... | datablock n |
55-
* +-----------+-------------+-------------+-------------+-----+-------------+
53+
* +-----------+-------------+-------------+-----+-------------+-------------+
54+
* |Fileheader | datablock 0 | datablock 1 | ... | datablock n | Appdx block |
55+
* +-----------+-------------+-------------+-----+-------------+-------------+
5656
*/
5757

5858
typedef struct fileHeaderV2_s {
@@ -151,11 +151,6 @@ typedef struct recordHeader_s {
151151
uint16_t size; // size of record including this header
152152
} recordHeader_t;
153153

154-
#define PushRecord(p, h, t) \
155-
recordHeader_t *h = (recordHeader_t *)p; \
156-
h->type = t; \
157-
h->size = sizeof(recordHeader_t);
158-
159154
#define TYPE_IDENT 0x8001
160155
#define TYPE_STAT 0x8002
161156

src/netflow/ipfix.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1502,7 +1502,7 @@ static void Process_ipfix_data(exporter_entry_t *exporter_entry, uint32_t Export
15021502
fs->nffile->stat_record->numpackets += genericFlow->inPackets;
15031503
fs->nffile->stat_record->numbytes += genericFlow->inBytes;
15041504

1505-
uint32_t exporterIdent = MetricExpporterID(recordHeaderV3);
1505+
uint32_t exporterIdent = MetricExporterID(recordHeaderV3);
15061506
UpdateMetric(fs->nffile->ident, exporterIdent, genericFlow);
15071507
}
15081508

src/netflow/netflow_v1.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -332,7 +332,7 @@ void Process_v1(void *in_buff, ssize_t in_buff_cnt, FlowSource_t *fs) {
332332
fs->nffile->stat_record->numpackets += genericFlow->inPackets;
333333
fs->nffile->stat_record->numbytes += genericFlow->inBytes;
334334

335-
uint32_t exporterIdent = MetricExpporterID(recordHeader);
335+
uint32_t exporterIdent = MetricExporterID(recordHeader);
336336
UpdateMetric(fs->nffile->ident, exporterIdent, genericFlow);
337337

338338
if (printRecord) {

src/netflow/netflow_v5_v7.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -494,7 +494,7 @@ void Process_v5_v7(void *in_buff, ssize_t in_buff_cnt, FlowSource_t *fs) {
494494
fs->nffile->stat_record->numpackets += genericFlow->inPackets;
495495
fs->nffile->stat_record->numbytes += genericFlow->inBytes;
496496

497-
uint32_t exporterIdent = MetricExpporterID(recordHeader);
497+
uint32_t exporterIdent = MetricExporterID(recordHeader);
498498
UpdateMetric(fs->nffile->ident, exporterIdent, genericFlow);
499499

500500
if (printRecord) {

src/netflow/netflow_v9.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1240,7 +1240,7 @@ static inline void Process_v9_data(exporter_entry_t *exporter_entry, void *data_
12401240
fs->nffile->stat_record->numpackets += genericFlow->inPackets;
12411241
fs->nffile->stat_record->numbytes += genericFlow->inBytes;
12421242

1243-
uint32_t exporterIdent = MetricExpporterID(recordHeaderV3);
1243+
uint32_t exporterIdent = MetricExporterID(recordHeaderV3);
12441244
UpdateMetric(fs->nffile->ident, exporterIdent, genericFlow);
12451245
}
12461246

src/netflow/nfd_raw.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,7 @@ void Process_nfd(void *in_buff, ssize_t in_buff_cnt, FlowSource_t *fs) {
277277
fs->nffile->stat_record->numpackets += genericFlow->inPackets;
278278
fs->nffile->stat_record->numbytes += genericFlow->inBytes;
279279

280-
uint32_t exporterIdent = MetricExpporterID(recordHeaderV3);
280+
uint32_t exporterIdent = MetricExporterID(recordHeaderV3);
281281
UpdateMetric(fs->nffile->ident, exporterIdent, genericFlow);
282282
}
283283

src/nfpcapd/flowdump.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ static int StorePcapFlow(flowParam_t *flowParam, struct FlowNode *Node) {
269269
stat_record->numpackets += genericFlow->inPackets;
270270
stat_record->numbytes += genericFlow->inBytes;
271271

272-
uint32_t exporterIdent = MetricExpporterID(recordHeader);
272+
uint32_t exporterIdent = MetricExporterID(recordHeader);
273273
UpdateMetric(fs->nffile->ident, exporterIdent, genericFlow);
274274

275275
if (printRecord) {

src/sflow/sflow_nfdump.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -530,7 +530,7 @@ void StoreSflowRecord(SFSample *sample, FlowSource_t *fs) {
530530
stat_record->numpackets += genericFlow->inPackets;
531531
stat_record->numbytes += genericFlow->inBytes;
532532

533-
uint32_t exporterIdent = MetricExpporterID(recordHeader);
533+
uint32_t exporterIdent = MetricExporterID(recordHeader);
534534
UpdateMetric(fs->nffile->ident, exporterIdent, genericFlow);
535535

536536
if (PrintRecord) {

0 commit comments

Comments
 (0)