ok folks, here's the last one for Today:

http://zlew.org/postgresql_static_check/scan-build-2009-08-23-29/

tar ball with report can be downloaded from here: http://zlew.org/postgresql_static_check/postgresql_static_check_23rdAugust2009.tar.xz (compressed with lzma's xz tool).

here's the patch for elog stuff:

Index: src/include/utils/elog.h
===================================================================
RCS file: /projects/cvsroot/pgsql/src/include/utils/elog.h,v
retrieving revision 1.101
diff -u -b -r1.101 elog.h
--- src/include/utils/elog.h    11 Jun 2009 14:49:13 -0000      1.101
+++ src/include/utils/elog.h    23 Aug 2009 22:16:05 -0000
@@ -104,7 +104,7 @@
  */
 #define ereport_domain(elevel, domain, rest)   \
        (errstart(elevel, __FILE__, __LINE__, PG_FUNCNAME_MACRO, domain) ? \
-        (errfinish rest) : (void) 0)
+        (errfinish rest) : (void) 0), (elevel >= ERROR) ? exit(1) : 0

 #define ereport(elevel, rest)  \
        ereport_domain(elevel, TEXTDOMAIN, rest)
@@ -190,7 +190,7 @@
  *             elog(ERROR, "portal \"%s\" not found", stmt->portalname);
  *----------
  */
-#define elog elog_start(__FILE__, __LINE__, PG_FUNCNAME_MACRO), elog_finish +#define elog(A, ...) elog_start(__FILE__, __LINE__, PG_FUNCNAME_MACRO), elog_finish(A, __VA_ARGS__), (A >= ERROR) ? exit(1) : 0

extern void elog_start(const char *filename, int lineno, const char *funcname);
 extern void


hopefully satisfying everyone.

Hope to see few fixes out of that ;)

thanks.




--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to