builtin: use tcc_backtrace for tcc (phase 2)

pull/5276/head^2
Delyan Angelov 2020-06-08 10:46:51 +03:00
parent 8a16086084
commit 6c9b2b8303
1 changed files with 2 additions and 2 deletions

View File

@ -65,6 +65,7 @@ fn print_backtrace_skipping_top_frames_freebsd(skipframes int) bool {
return true
}
fn C.tcc_backtrace(fmt charptr, other ...charptr) int
fn print_backtrace_skipping_top_frames_linux(skipframes int) bool {
$if android {
eprintln('On Android no backtrace is available.')
@ -76,8 +77,7 @@ fn print_backtrace_skipping_top_frames_linux(skipframes int) bool {
return false
}
$if tinyc {
eprintln('TODO: print_backtrace_skipping_top_frames_linux $skipframes')
eprintln('with tcc fails tests with "stack smashing detected" .')
C.tcc_backtrace("Backtrace")
return false
}
buffer := [100]byteptr