diff options
| author | Andrey Konovalov <andreyknvl@google.com> | 2017-07-24 16:56:25 +0200 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2017-07-24 20:50:42 +0200 |
| commit | c70b8a2cff49bd066bb4f246a4d36bd848ea7b22 (patch) | |
| tree | 2e39803ab2956fc6280f558ef73472c156b4808c /pkg | |
| parent | 7b42b1cf9e47b1391aa7ccbebfc40b4a49783233 (diff) | |
pkg/report: fix symbolization of old KASAN stack trace format
Which has a tab instead of a space at the beginning of each frame
in alloc and free stack traces.
Diffstat (limited to 'pkg')
| -rw-r--r-- | pkg/report/report.go | 2 | ||||
| -rw-r--r-- | pkg/report/report_test.go | 5 |
2 files changed, 6 insertions, 1 deletions
diff --git a/pkg/report/report.go b/pkg/report/report.go index 12e5ead7d..d5c5e0b21 100644 --- a/pkg/report/report.go +++ b/pkg/report/report.go @@ -343,7 +343,7 @@ var oopses = []*oops{ var ( consoleOutputRe = regexp.MustCompile(`^(?:\<[0-9]+\>)?\[ *[0-9]+\.[0-9]+\] `) questionableRe = regexp.MustCompile(`(?:\[\<[0-9a-f]+\>\])? \? +[a-zA-Z0-9_.]+\+0x[0-9a-f]+/[0-9a-f]+`) - symbolizeRe = regexp.MustCompile(`(?:\[\<(?:[0-9a-f]+)\>\])? +(?:[0-9]+:)?([a-zA-Z0-9_.]+)\+0x([0-9a-f]+)/0x([0-9a-f]+)`) + symbolizeRe = regexp.MustCompile(`(?:\[\<(?:[0-9a-f]+)\>\])?[ \t]+(?:[0-9]+:)?([a-zA-Z0-9_.]+)\+0x([0-9a-f]+)/0x([0-9a-f]+)`) decNumRe = regexp.MustCompile(`[0-9]{5,}`) lineNumRe = regexp.MustCompile(`(:[0-9]+)+`) addrRe = regexp.MustCompile(`[0-9a-f]{8,}`) diff --git a/pkg/report/report_test.go b/pkg/report/report_test.go index f811b36f7..92844fe97 100644 --- a/pkg/report/report_test.go +++ b/pkg/report/report_test.go @@ -970,6 +970,11 @@ func TestSymbolizeLine(t *testing.T) { " [<ffffffff84e5bea0>] do_ipv6_setsockopt.isra.7.part.3+0x101/0x2830 \n", " [<ffffffff84e5bea0>] do_ipv6_setsockopt.isra.7.part.3+0x101/0x2830 net.c:111 \n", }, + // Old KASAN frame format (with tab). + { + "[ 50.419727] baz+0x101/0x200\n", + "[ 50.419727] baz+0x101/0x200 baz.c:100\n", + }, // Inlined frames. { " [<ffffffff84e5bea0>] foo+0x141/0x185\n", |
