go-libaudit
go-libaudit copied to clipboard
Check fieldalignment in golangci-lint
In #117 some alignment issues were fixed. This will help prevent future regressions.
:green_heart: Build Succeeded
the below badges are clickable and redirect to their specific view in the CI or DOCS
![]()
![]()
![]()
![]()
![]()
Expand to view the summary
Build stats
-
Start Time: 2022-07-14T20:09:00.656+0000
-
Duration: 2 min 13 sec
Test stats :test_tube:
| Test | Results |
|---|---|
| Failed | 0 |
| Passed | 386 |
| Skipped | 40 |
| Total | 426 |
On the basis of experiments that I did to see the performance impact of pointer byte count (essentially none) I'm having second thought about this.
As https://github.com/elastic/go-libaudit/pull/117 is neither approved nor merged, this change should report at least some unaligned structs.
Also for auditRuleData I would expect a nolint instruction, as fieldalignment is not happy how the kernel orders the struct that is passed to user space and parsed. From a Go perspective []byte should be placed before auditRuleHeader but this will break parsing.