Commit 0f0662c
committed
pf: Fix error handling in pf_handle_get_tstats()
- pfr_table_count() can return an error.
- We must check for failure from mallocarray(M_NOWAIT).
Fixes: 9e8d296 ("pf: convert DIOCRGETTSTATS to netlink")
Reported by: Kevin Day <[email protected]>
Reviewed by: kp
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D540941 parent 73586fc commit 0f0662c
1 file changed
+10
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1954 | 1954 | | |
1955 | 1955 | | |
1956 | 1956 | | |
| 1957 | + | |
| 1958 | + | |
| 1959 | + | |
| 1960 | + | |
| 1961 | + | |
1957 | 1962 | | |
1958 | 1963 | | |
| 1964 | + | |
| 1965 | + | |
| 1966 | + | |
| 1967 | + | |
| 1968 | + | |
1959 | 1969 | | |
1960 | 1970 | | |
1961 | 1971 | | |
| |||
0 commit comments