fix offset in addr2line

This commit is contained in:
Pablo Galindo Salgado 2025-09-23 19:40:40 +01:00 committed by Dino Viehland
parent f3f5795e31
commit 44a3e46770

View file

@ -3804,7 +3804,7 @@ _PyImport_LoadLazyImportTstate(PyThreadState *tstate, PyObject *lazy_import)
}
/* Resolve line number from instruction offset on demand */
int lineno = PyCode_Addr2Line((PyCodeObject *)lz->lz_code, lz->lz_instr_offset);
int lineno = PyCode_Addr2Line((PyCodeObject *)lz->lz_code, lz->lz_instr_offset*2);
/* Get strings - these can return NULL on encoding errors */
const char *filename_str = PyUnicode_AsUTF8(lz->lz_code->co_filename);