From 1ae3e29ea3fd90e5df31d52c5d3860fde7f3cbac Mon Sep 17 00:00:00 2001 From: couriersud Date: Wed, 18 Jan 2017 00:32:12 +0100 Subject: Assume string literals are UTF8 in netlist code. At the same time, any char pointer has to be explicitly converted to pstring by specifying an encoding. Not yet optimal, but certainly better than what was there before. Removed unneeded methods from pstring. (nw) --- src/lib/netlist/plib/putil.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/lib/netlist/plib/putil.cpp') diff --git a/src/lib/netlist/plib/putil.cpp b/src/lib/netlist/plib/putil.cpp index 39e1b444f33..b21f945662c 100644 --- a/src/lib/netlist/plib/putil.cpp +++ b/src/lib/netlist/plib/putil.cpp @@ -36,7 +36,7 @@ namespace plib if (getenv(var.c_str()) == nullptr) return default_val; else - return pstring(getenv(var.c_str())); + return pstring(getenv(var.c_str()), pstring::UTF8); } } @@ -139,7 +139,7 @@ namespace plib if (*str == ',') { *bufp = 0; - return pstring(buf); + return pstring(buf, pstring::UTF8); } else if (*str != ' ') *bufp++ = *str; @@ -152,6 +152,6 @@ namespace plib str++; } *bufp = 0; - return pstring(buf); + return pstring(buf, pstring::UTF8); } } // namespace plib -- cgit v1.2.3-70-g09d2