gh-127604: Replace dprintf() with _Py_write_noraise()#132854
gh-127604: Replace dprintf() with _Py_write_noraise()#132854vstinner merged 2 commits intopython:mainfrom
Conversation
ZeroIntensity
left a comment
There was a problem hiding this comment.
I wasn't aware of _Py_DumpHexadecimal, this works a lot better than the mess of dup and file APIs in #132800. Thanks!
|
This introduced a compiler warning: Python/traceback.c:883:1: warning: ‘dump_pointer’ defined but not used [-Wunused-function]
883 | dump_pointer(int fd, void *ptr)
| ^~~~~~~~~~~~Maybe the function should also be behind an |
I wrote #132897 to fix the warning. On which machine/OS did you see the warning? |
|
Aha, now I can see the warning on the WASI build. The configure script says: |
I saw it on Ubuntu 24.04 |
Ok, good to know. I suppose that you miss Anyway, the warning was fixed by c292f7f. Thanks for the report. |
|
Interesting, I do have the extern int backtrace (void **__array, int __size) __nonnull ((1));
extern char **backtrace_symbols (void *const *__array, int __size)
__THROW __nonnull ((1));
extern void backtrace_symbols_fd (void *const *__array, int __size, int __fd)
__THROW __nonnull ((1)); |
|
Sorry, it's @ZeroIntensity: By the way, |
|
Yup, but I don't know of a system that provides |
faulthandler#127604