mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 12:01:16 +00:00
- new_* functions in general moved to version without new_ prefix.
- `string::new_from_*` changed to `string::from_*`. - `String.to_utf16_copy` and related changed to `String.to_utf16`. - `String.to_utf16_tcopy` and related changed to `String.to_temp_utf16` - `mem::temp_new` changed to `mem::tnew`. - `mem::temp_alloc` and related changed to `mem::talloc`. - `mem::temp_new_array` changed to `mem::temp_array`.
This commit is contained in:
committed by
Christoffer Lerno
parent
b35aafd3d5
commit
c40198b016
@@ -130,7 +130,7 @@ fn ulong! elf_module_image_base(String path) @local
|
||||
|
||||
fn void! backtrace_add_from_exec(Allocator allocator, BacktraceList* list, void* addr) @local
|
||||
{
|
||||
char[] buf = mem::temp_alloc_array(char, 1024);
|
||||
char[] buf = mem::talloc_array(char, 1024);
|
||||
|
||||
String exec_path = process::execute_stdout_to_buffer(buf, {"realpath", "-e", string::tformat("/proc/%d/exe", posix::getpid())})!;
|
||||
String obj_name = exec_path.copy(allocator);
|
||||
@@ -140,7 +140,7 @@ fn void! backtrace_add_from_exec(Allocator allocator, BacktraceList* list, void*
|
||||
|
||||
fn void! backtrace_add_from_dlinfo(Allocator allocator, BacktraceList* list, void* addr, Linux_Dl_info* info) @local
|
||||
{
|
||||
char[] buf = mem::temp_alloc_array(char, 1024);
|
||||
char[] buf = mem::talloc_array(char, 1024);
|
||||
|
||||
void* obj_addr = addr - (uptr)info.dli_fbase + (uptr)elf_module_image_base(info.dli_fname.str_view())!;
|
||||
ZString obj_path = info.dli_fname;
|
||||
|
||||
Reference in New Issue
Block a user