dbmirror bug - Mailing list pgsql-bugs

From Hai-Chen Tu
Subject dbmirror bug
Date
Msg-id 20021120171908.59530.qmail@web9305.mail.yahoo.com
Whole thread Raw
List pgsql-bugs
Your name               : Hai-Chen Tu
Your email address      : hctu@yahoo.com


System Configuration
---------------------
  Architecture (example: Intel Pentium)         :

  Operating System (example: Linux 2.0.26 ELF)  :

  PostgreSQL version (example: PostgreSQL-7.3):
PostgreSQL-7.3

  Compiler used (example:  gcc 2.95.2)          :


Please enter a FULL description of your problem:
------------------------------------------------
dbmirror generates "out of memory" error in some
cases when the DEBUG_OUTPUT is enabled.




Please describe a way to repeat the problem.   Please
try to provide a
concise reproducible example, if at all possible:
----------------------------------------------------------------------
The cause of the problem is that dbmirror
uses
    elog(NOTICE, cpKeyData)
and
    elog(NOTICE, cpFieldData)
to print column data where elog
interprets the second argument as sprintf
format string, which fails if
cpKeyData/cpFieldData contains '%'.




If you know how this problem might be fixed, list the
solution below:
---------------------------------------------------------------------

The solution is to change
    elog(NOTICE, ...)
to
    elog(NOTICE, "%s", ...)

This applies to all cpKeyData and cpFieldData,
and probably cpFieldName(?).


__________________________________________________
Do you Yahoo!?
Yahoo! Web Hosting - Let the expert host your site
http://webhosting.yahoo.com

pgsql-bugs by date:

Previous
From: Weber Gerhard
Date:
Subject: version for sun cobalt qube 3
Next
From: "Tamotsu Ebina"
Date:
Subject: Can't start postmaster on Cygwin with local 'ja_JP.EUC