From: SourceForge.net <no...@so...> - 2004-08-25 11:20:59
|
Bugs item #1006782, was opened at 2004-08-10 20:49 Message generated for change (Comment added) made by ghum You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=116528&aid=1006782&group_id=16528 Category: libpq Group: None Status: Open Resolution: None Priority: 5 Submitted By: Harald Armin Massa (ghum) Assigned to: Nobody/Anonymous (nobody) Summary: pyPGSQL does not connect to PostgreSQL 8.0 Beta Initial Comment: While trying to connect to Postgresql 8.0, PyPGSQL raises Invalid format for PgVersion construction. Error. That's seems to be within PyObject *PgVersion_New(char *version) of pgversion.c What is going wrong? ---------------------------------------------------------------------- >Comment By: Harald Armin Massa (ghum) Date: 2004-08-25 13:20 Message: Logged In: YES user_id=665785 correcting myself... if (pgstricmp(last, "beta") == 0) return (errno != 0); pgstricmp does not take any length parameter ---------------------------------------------------------------------- Comment By: Harald Armin Massa (ghum) Date: 2004-08-25 13:19 Message: Logged In: YES user_id=665785 Thank you very much, mfuhr... I looked at the "devel" check and propose to do if (pgstricmp(last, "beta", 4) == 0) return (errno != 0); instead of strncmp ... I suppose the PostgreSQL developers had their reason to provide their own strcmp, or? ---------------------------------------------------------------------- Comment By: Michael Fuhr (mfuhr) Date: 2004-08-24 05:47 Message: Logged In: YES user_id=655499 PgVersion_New() calls parseToken(), which doesn't allow for the string "beta" in the last token of "8.0.0beta1". parseToken() checks for "devel" and a few other cases, but not for "beta". I got it to work by adding the following lines after the check for "devel": if (strncmp(last, "beta", 4) == 0) return (errno != 0); ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=116528&aid=1006782&group_id=16528 |