changeset 1857:79c0c22e13ae

Postgres unicode printing fix from Artyom Shalkhakov
author Adam Chlipala <adam@chlipala.net>
date Wed, 17 Jul 2013 09:09:48 -0400
parents 3683d1a8c1c8
children 2a0b9603d8af
files src/c/urweb.c
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/c/urweb.c	Sat Jun 15 08:18:47 2013 -0400
+++ b/src/c/urweb.c	Wed Jul 17 09:09:48 2013 -0400
@@ -2451,7 +2451,7 @@
       if (isprint((int)c))
         *s2++ = c;
       else if (uw_Estrings) {
-        sprintf(s2, "\\%03o", c);
+        sprintf(s2, "\\%03o", (unsigned char)c);
         s2 += 4;
       }
       else
@@ -2494,7 +2494,7 @@
     if (isprint((int)c))
       *s2++ = c;
     else if (uw_Estrings) {
-      sprintf(s2, "\\%03o", c);
+      sprintf(s2, "\\%03o", (unsigned char)c);
       s2 += 4;
     }
     else