On Tue, 24 Nov 2015 11:38:00 -0500
"D'Arcy J.M. Cain" <[email protected]> wrote:
> drastic fix though.  Did you consider casting to unsigned int?  I
> suspect that the problem was chars > 127 being converted to negative
> numbers.  The only negative number allowed to those macros is -1.

Life is a bit crazy here today.  That was not a good fix.  The real fix
is to make the buffers unsigned char.  In fact, I have always said that
chars should never be signed by default.  It makes no sense to have
negative characters.  If you want small ints, use small ints.

My suggestion is to revert that last change and instead do this:

Index: setup.py
===================================================================
--- setup.py    (revision 619)
+++ setup.py    (working copy)
@@ -87,7 +87,7 @@
 library_dirs = [get_python_lib(), pg_config('libdir')]
 define_macros = [('PYGRESQL_VERSION', version)]
 undef_macros = []
-extra_compile_args = ['-O2', '-Wall', '-Werror']
+extra_compile_args = ['-O2', '-Wall', '-Werror', '-funsigned-char']

I can commit that and the revert if you agree or you can.

-- 
D'Arcy J.M. Cain
PyGreSQL Development Group
http://www.PyGreSQL.org IM:[email protected]
_______________________________________________
PyGreSQL mailing list
[email protected]
https://mail.vex.net/mailman/listinfo.cgi/pygresql

Reply via email to