Commit 74a1a0f
Fix up parseUpToLen(). (#46)
The parseUpToLen function would not handle the max chars limit.
Found when using a syslog client which used > max chars for the
APP-NAME. I changed the syslog client to use max chars and it still
didn't work. There was an off by 1 error. One of the tests even
gave a max chars string and expected an error - changed that test
to try with max+1 chars.1 parent 11c69e4 commit 74a1a0f
File tree
3 files changed
+19
-3
lines changed- format
- internal/syslogparser/rfc5424
3 files changed
+19
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
88 | | - | |
| 88 | + | |
89 | 89 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
579 | 579 | | |
580 | 580 | | |
581 | 581 | | |
582 | | - | |
| 582 | + | |
583 | 583 | | |
584 | 584 | | |
585 | 585 | | |
| |||
588 | 588 | | |
589 | 589 | | |
590 | 590 | | |
| 591 | + | |
| 592 | + | |
591 | 593 | | |
592 | 594 | | |
593 | 595 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
| 25 | + | |
25 | 26 | | |
26 | 27 | | |
27 | 28 | | |
| |||
60 | 61 | | |
61 | 62 | | |
62 | 63 | | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
63 | 77 | | |
64 | 78 | | |
65 | 79 | | |
| |||
684 | 698 | | |
685 | 699 | | |
686 | 700 | | |
687 | | - | |
| 701 | + | |
688 | 702 | | |
689 | 703 | | |
690 | 704 | | |
| |||
0 commit comments