Commit Graph

17630 Commits

Author SHA1 Message Date
Tom Lane 6daef2bca4 Remove hack in pg_tablespace_aclmask() that disallowed permissions
on pg_global even to superusers, and replace it with checks in various
other places to complain about invalid uses of pg_global.  This ends
up being a bit more code but it allows a more specific error message
to be given, and it un-breaks pg_tablespace_size() on pg_global.
Per discussion.
2007-10-12 18:55:12 +00:00
Tom Lane 2b0c86b665 Ensure that the result of evaluating a function during constant-expression
simplification gets detoasted before it is incorporated into a Const node.
Otherwise, if an immutable function were to return a TOAST pointer (an
unlikely case, but it can be made to happen), we would end up with a plan
that depends on the continued existence of the out-of-line toast datum.
2007-10-11 21:27:49 +00:00
Tom Lane 56b7695cf5 Remove incorrect use of VARSIZE() on a toasted datum. We can just remove it
instead of fix it, since once we've set toast_action[i] to 'p' it no longer
matters what toast_sizes[i] is.  Greg Stark
2007-10-11 18:19:58 +00:00
Tom Lane 82d8ab6fc4 Fix the plan-invalidation mechanism to treat regclass constants that refer to
a relation as a reason to invalidate a plan when the relation changes.  This
handles scenarios such as dropping/recreating a sequence that is referenced by
nextval('seq') in a cached plan.  Rather than teach plancache.c all about
digging through plan trees to find regclass Consts, we charge the planner's
setrefs.c with making a list of the relation OIDs on which each plan depends.
That way the list can be built cheaply during a plan tree traversal that has
to happen anyway.  Per bug #3662 and subsequent discussion.
2007-10-11 18:05:27 +00:00
Magnus Hagander fb074439ae Add missing codepage numbers for Windows.
Dave Page
2007-10-10 11:50:07 +00:00
Michael Meskes ea82ad6aff Synced parser and keyword list. 2007-10-10 06:33:17 +00:00
Magnus Hagander 20c38514b4 Don't try to free pgpassfile since it's a stack variable.
Martin Pitt
2007-10-09 15:03:27 +00:00
Bruce Momjian fe385795a1 Add comment. 2007-10-09 02:56:44 +00:00
Tom Lane 298c457520 Make dumpcolors() have tolerable performance when using 32-bit chr,
as we do (and upstream Tcl doesn't).  The loop limit might be subject
to negotiation if anyone ever tries to do regex debugging in Far
Eastern languages, but for now 1000 seems plenty.  CHR_MAX was right out :-(
2007-10-06 16:18:09 +00:00
Tom Lane 06ce02f989 Adjust some regex debugging printouts to not give wrong-format-width
warnings on a 64-bit machine.  Noted while chasing a recent regex
bug report.
2007-10-06 16:05:54 +00:00
Tom Lane c4db0d9ae1 Adjust regcustom.h so that all those assert() calls in the regex package
are converted to Postgres Assert() macros, instead of using <assert.h>
as formerly.  No difference in production builds, but --enable-cassert
debug builds will get better coverage for regex testing.
2007-10-06 16:01:51 +00:00
Bruce Momjian 41f8f37474 Add comment about cvs branch numbers. 2007-10-05 18:40:52 +00:00
Tom Lane 9403598059 Fix plperl and pltcl to include the name of the current function when
passing on errors from the language interpreter.  (plpython seems
fairly OK about this already.)  Per gripe from Robert Kleemann.
2007-10-05 17:06:11 +00:00
Bruce Momjian e77df38a0f Add pgcvslog '-d' capability to allow stripping of commit messages that
have back branch activity.  This will be useful for creating release
notes for major releases.
2007-10-05 16:42:32 +00:00
Tom Lane eefd10c66c Fix distprep and maintainer-clean targets so that ecpg's .def files are
made and removed at the correct times.
2007-10-05 01:51:40 +00:00
Tom Lane b8f41d508c Add .cvsignore files to suppress CVS gripes about ecpg .def files. 2007-10-05 01:35:55 +00:00
Tom Lane 8dfca24b6b Results from buildfarm show that ecpglib was depending on pg_strcasecmp,
which evidently it got as an unofficial export from pgtypeslib.
2007-10-04 20:54:08 +00:00
Tom Lane 89db887b1e Keep the planner from failing on "WHERE false AND something IN (SELECT ...)".
eval_const_expressions simplifies this to just "WHERE false", but we have
already done pull_up_IN_clauses so the IN join will be done, or at least
planned, anyway.  The trouble case comes when the sub-SELECT is itself a join
and we decide to implement the IN by unique-ifying the sub-SELECT outputs:
with no remaining reference to the output Vars in WHERE, we won't have
propagated the Vars up to the upper join point, leading to "variable not found
in subplan target lists" error.  Fix by adding an extra scan of in_info_list
and forcing all Vars mentioned therein to be propagated up to the IN join
point.  Per bug report from Miroslav Sulc.
2007-10-04 20:44:47 +00:00
Tom Lane 87dfa0d9ae Stamp 8.3beta1, except in configure.in/configure. 2007-10-04 19:12:04 +00:00
Tom Lane 08e5749c6d Update timezone data files to release 2007h of the zic database.
Might as well have the latest when we wrap 8.3beta1.
2007-10-04 19:06:59 +00:00
Tom Lane c86ce06964 DLL_DEFFILE should be defined when PORTNAME is win32, not when it isn't,
per the example of libpq/Makefile.
2007-10-04 18:32:07 +00:00
Michael Meskes 746593efe6 Replaced tabs by white spaces 2007-10-04 17:49:31 +00:00
Michael Meskes 085ffb24dc Removed newline at end of exports files. 2007-10-04 16:29:33 +00:00
Tom Lane b26738b583 Change Assert() to a plain test and elog, just to see if that works
around the icc bug exhibited by buildfarm member dugong.
2007-10-04 15:37:44 +00:00
Michael Meskes 133d77a906 Added def-files to all: target so they are build everytime. 2007-10-04 07:58:15 +00:00
Tom Lane a8dfe119bd Teach chklocale.c how to extract encoding info from Windows locale
names.  ITAGAKI Takahiro
2007-10-03 17:16:39 +00:00
Tom Lane b3ab9b45da Suppress compiler warning in non-threaded build. 2007-10-03 16:03:25 +00:00
Tom Lane 6cbb2353cb Tweak recently-added tests to suppress scary-looking warnings on 64-bit
machines about casts between pointers and integers of different sizes.
While they're harmless, we shouldn't expect users to have to go through
and figure that out for themselves.
2007-10-03 15:59:13 +00:00
Michael Meskes 2b0e46eef0 Argh, missing dll in filename 2007-10-03 15:24:19 +00:00
Tom Lane fdbce93b85 Minor improvements to hack for old OpenSSL libraries: avoid unused
variable warning on Windows, improve comment.
2007-10-03 15:12:45 +00:00
Tom Lane a248dbc4f8 Fix command for fetching snprintf.c. 2007-10-03 15:04:23 +00:00
Michael Meskes f06a2b0ecc This could be what's missing on some systems. 2007-10-03 14:42:16 +00:00
Michael Meskes c95f5e80a9 Stripped two symbols that are needed. 2007-10-03 14:01:28 +00:00
Magnus Hagander 76a6ddfa47 Attempt to open certificate file "manually" using fopen before
trying BIO functions.
Helps problem with older versions of OpenSSL that lacks error
stack functions and would show an incorrect error message for
file-not-found-or-not-openable. The problem may still exist for
other errors, but file open error is by far the most common one.
2007-10-03 13:57:52 +00:00
Magnus Hagander 2890c33084 Build two more .DEF files for ecpg instead of using default ones. 2007-10-03 13:43:24 +00:00
Michael Meskes ab8d123a3c Also build snprintf from pgport if needed. 2007-10-03 13:40:52 +00:00
Michael Meskes 449fcf47fb Remove exports.list in clean target. 2007-10-03 13:24:54 +00:00
Magnus Hagander bdf6b888a8 More detailed error msg (with stack trace) if a file copy fails. 2007-10-03 13:20:40 +00:00
Michael Meskes fa8a9f373c Also created export list for pgytpeslib and compatlib.
Set pgtypes library version to 3.0.
Set compat library version to 3.0.
2007-10-03 13:20:19 +00:00
Magnus Hagander f83e44aecd Use snprintf from libpgport in ecpg compatlib. Required since
we restricted exports from ecpglib.
2007-10-03 12:34:29 +00:00
Magnus Hagander 7b4453e5c1 Fix commandlines for final two ECPG regression tests 2007-10-03 12:31:18 +00:00
Magnus Hagander 5d0f18d6ad Fix typo 2007-10-03 12:11:37 +00:00
Magnus Hagander c8792c86f2 Build DEF file for libecpg instead of generating a default one. 2007-10-03 12:11:00 +00:00
Magnus Hagander 6ddbc1164d Make ECPG regression tests run with -c only for array_of_struct.pgc
on MSVC.

Fix strange nonstandard version of __stdcall specifyer in thread
tests on win32.
2007-10-03 11:57:36 +00:00
Magnus Hagander ebade3f5bf Fix typo 2007-10-03 11:34:11 +00:00
Michael Meskes 7793c6ecca Cleaned up ecpglib and renamed functions that do not need to be exported.
Created export list for ecpglib.
2007-10-03 11:11:12 +00:00
Michael Meskes c4a6c2f871 Hopefully fixed some stuff that causes Windows builds to fail. 2007-10-03 08:55:23 +00:00
Neil Conway fc470ca334 Fix a compiler warning on Win32. Hannes Eder. 2007-10-02 22:01:02 +00:00
Magnus Hagander de1172fa06 Default to thread safety on, and support more CPU options. Also
make sure that a CPU option is actually chosen.

Hiroshi Saito
2007-10-02 19:01:45 +00:00
Michael Meskes 5a0d31d3dc Made new test also work without threading enabled. 2007-10-02 14:01:57 +00:00