From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 92898 invoked by alias); 18 Dec 2015 18:24:43 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 92876 invoked by uid 89); 18 Dec 2015 18:24:42 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.6 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_LOW autolearn=no version=3.3.2 spammy=H*f:sk:001a114, H*i:sk:001a114, H*MI:sk:001a114, sk:python X-HELO: rock.gnat.com Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Fri, 18 Dec 2015 18:24:42 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id 5805211684D; Fri, 18 Dec 2015 13:24:40 -0500 (EST) Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id wdpSLhv051gx; Fri, 18 Dec 2015 13:24:40 -0500 (EST) Received: from joel.gnat.com (localhost.localdomain [127.0.0.1]) by rock.gnat.com (Postfix) with ESMTP id ED3421167C3; Fri, 18 Dec 2015 13:24:39 -0500 (EST) Received: by joel.gnat.com (Postfix, from userid 1000) id 18162406CD; Fri, 18 Dec 2015 22:24:36 +0400 (RET) Date: Fri, 18 Dec 2015 18:24:00 -0000 From: Joel Brobecker To: Doug Evans Cc: gdb-patches@sourceware.org Subject: Re: [PATCH] Add function host_string_to_python_string. Message-ID: <20151218182436.GG29928@adacore.com> References: <001a11438f7c8987ea05272ff754@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <001a11438f7c8987ea05272ff754@google.com> User-Agent: Mutt/1.5.23 (2014-03-12) X-SW-Source: 2015-12/txt/msg00377.txt.bz2 > There's a python_string_to_host_string function, but not its counterpart. > I couldn't find anything in the record arguing against its existence, > and there's enough of a use for it so I added it. > > Regression tested on amd64-linux. > > 2015-12-18 Doug Evans > > * python/py-utils.c (host_string_to_python_string): New function. > * python/python-internal.h (host_string_to_python_string): Declare it. > * python/py-*.c (*): Update all calls to > PyString_Decode (str, strlen (str), host_charset (), NULL) > to use host_string_to_python_string (str) instead. FWIW, looking at the alternative, I find the new one much better, so that's a nice addition, IMO. -- Joel