Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:jeff_mahoney:crash-python:devel
gdb
0002-python-use-utf-8-encoding-for-gdb_write.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0002-python-use-utf-8-encoding-for-gdb_write.patch of Package gdb
From 94f31e23baf1db032569bcdd4774a2f01195e27e Mon Sep 17 00:00:00 2001 From: Jeff Mahoney <jeffm@suse.com> Date: Sat, 13 Apr 2019 23:01:18 -0400 Subject: [PATCH 02/17] python: use utf-8 encoding for gdb_write Routine print operations end up getting encoding exceptions since the default encoding is ascii. Most systems are using utf-8 now so let's use that instead. This is a hack and we should be looking at the locale. Signed-off-by: Jeff Mahoney <jeffm@suse.com> --- gdb/python/python.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gdb/python/python.c b/gdb/python/python.c index 91636ef0225..26278bdfbd0 100644 --- a/gdb/python/python.c +++ b/gdb/python/python.c @@ -1307,8 +1307,8 @@ gdbpy_write (PyObject *self, PyObject *args, PyObject *kw) static const char *keywords[] = { "text", "stream", NULL }; int stream_type = 0; - if (!gdb_PyArg_ParseTupleAndKeywords (args, kw, "s|i", keywords, &arg, - &stream_type)) + if (!gdb_PyArg_ParseTupleAndKeywords (args, kw, "es|i", keywords, "utf-8", + &arg, &stream_type)) return NULL; try -- 2.37.2
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor