1
0
mirror of https://github.com/postgres/postgres.git synced 2025-11-26 23:43:30 +03:00
Commit Graph

14395 Commits

Author SHA1 Message Date
Tom Lane
76f13fe78d interval_out failed to mention 'ago' for negative intervals in SQL and
GERMAN datestyles.  Ancient bug reported by Terry Lee Tucker.
2005-01-11 18:34:29 +00:00
Tom Lane
e333705b84 array_map failed to insert correct result type in an empty array.
Per example from Florian Pflug.
2004-12-17 20:58:47 +00:00
Tom Lane
bd677bb443 Back-patch fix for ALTER DATABASE failing to flush pg_database changes
to disk right away.  This is just a one-liner change rather than trying
to use FlushRelationBuffers().
2004-11-18 01:19:57 +00:00
Tom Lane
eac07f1fd7 Fix off-by-one memory allocation, as reported by Rod Taylor. Also
avoid repalloc'ing twice when once is sufficient.
2004-11-17 19:54:53 +00:00
Tom Lane
42a8068b5c Stamp release 7.3.8. REL7_3_8 2004-10-22 00:27:05 +00:00
Tom Lane
0b83c1f272 Prevent pg_ctl from being run as root. Since it uses configuration files
owned by postgres, doing "pg_ctl start" as root could allow a privilege
escalation attack, as pointed out by iDEFENSE.  Of course the postmaster would
fail, but we ought to fail a little sooner to protect sysadmins unfamiliar
with Postgres.  The chosen fix is to disable root use of pg_ctl in all cases,
just to be confident there are no other holes.
2004-10-22 00:24:33 +00:00
Tom Lane
d9c1e5e1c2 Back-patch make_oidjoins_check security improvement. 2004-10-21 17:12:27 +00:00
Tom Lane
78c0692b15 Repair possible failure to update hint bits back to disk, per
http://archives.postgresql.org/pgsql-hackers/2004-10/msg00464.php.
I plan a more permanent fix in HEAD, but for the back branches it seems
best to just touch the places that actually have a problem.
2004-10-13 22:22:22 +00:00
Tom Lane
8a9b331c32 Fix breakage in hashjoin from recent backpatch of left-join bug fix.
(That's what I get for not testing the back branches *before* committing.)
2004-10-13 21:56:06 +00:00
Tom Lane
c57bcb7b2c Hashed LEFT JOIN would miss outer tuples with no inner match if the join
was large enough to be batched and the tuples fell into a batch where
there were no inner tuples at all.  Thanks to Xiaoyu Wang for finding a
test case that exposed this long-standing bug.
2004-09-17 18:29:24 +00:00
Tom Lane
1cfe0a407d Wups, seem to have used an ungood version of lynx to generate this. REL7_3_7 2004-08-15 01:27:47 +00:00
Tom Lane
1bc489bc9c Stamp 7.3.7. 2004-08-15 00:52:02 +00:00
Tom Lane
25ad99245a Fix failure to guarantee that a checkpoint will write out pg_clog updates
for transaction commits that occurred just before the checkpoint.  This is
an EXTREMELY serious bug --- kudos to Satoshi Okada for creating a
reproducible test case to prove its existence.
2004-08-11 04:08:40 +00:00
Teodor Sigaev
144dc30554 Remove asymetrical word processing in query and text 2004-06-07 16:49:25 +00:00
Peter Eisentraut
6122f38b0a Translation updates 2004-04-05 09:02:37 +00:00
Peter Eisentraut
6f8f414d30 Translation updates 2004-04-05 08:45:37 +00:00
Tom Lane
e921472fef Always schema-qualify the name of a function referenced in CREATE CAST.
The former coding failed if the cast function was not in the pg_catalog
schema.  How'd this escape detection?
2004-03-02 21:15:15 +00:00
Tom Lane
2d558b2baa Brand 7.3.6. REL7_3_6 2004-03-02 00:44:55 +00:00
Tom Lane
040f11db24 Update release notes for 7.3.6. 2004-03-02 00:39:09 +00:00
Tom Lane
d367707827 Replace unportable use of /dev/stdin with lynx's -stdin switch. 2004-03-02 00:03:15 +00:00
Joe Conway
a7e5e2fe74 When returning type "record", replace use of pgresultGetTupleDesc
with ReturnSetInfo->expectedDesc. This allows custom datatypes
(e.g. from tsearch2) to be returned at runtime. Previous behavior
depended on the type oid to match between the remote and local
database, which obviously doesn't work well for custom types.
Per report from Mark Gibson.
2004-02-24 06:07:52 +00:00
Joe Conway
7ce7e3f036 pply quote_literal to the start_with argument of connectby. Fixes problem
reported by David Garamond when working with bytea parent and child keys.
2004-02-24 05:26:27 +00:00
Tom Lane
d301dcbe30 Don't crash when a rowtype argument to a plpgsql function is NULL.
Per report from Chris Campbell.
2004-02-24 01:44:58 +00:00
Tom Lane
8fd0eb8c7a Back-patch fix for ReadOffset with off_t wider than int. 2004-02-05 22:12:48 +00:00
Tom Lane
3c373885fa Do not let external specification of CFLAGS stop us from adding
-fno-strict-aliasing.
2004-02-02 04:08:12 +00:00
Tom Lane
a60442a446 Avoid generating invalid character encoding sequences in make_greater_string.
Not sure how this mistake evaded detection for so long.
2004-02-02 03:07:25 +00:00
Joe Conway
b59917f02e Fix text_position to not scan past end of source string in multibyte
case, per report from Korea PostgreSQL Users' Group. Copied from Tom
Lane's 7.4 branch patch.
2004-02-01 04:05:13 +00:00
Tom Lane
1b25db6a3c Repair incorrect order of operations in GetNewTransactionId(). We must
complete ExtendCLOG() before advancing nextXid, so that if that routine
fails, the next incoming transaction will try it again.  Per trouble
report from Christopher Kings-Lynne.
2004-01-26 19:16:40 +00:00
Tom Lane
15ae5d26a0 Revert ill-starred change of 13-Feb-02: it appeared to fix a problem of
incorrect permissions checking, but in fact disabled most all permissions
checks for view updates.  This corrects problems reported by Sergey
Yatskevich among others, at the cost of re-introducing the problem
previously reported by Tim Burgess.  However, since we'd lived with that
problem for quite awhile without knowing it, we can live with it awhile
longer until a proper fix can be made in 7.5.
2004-01-14 03:39:36 +00:00
Joe Conway
c9eb119353 Repair indexed bytea like operations, and related selectivity
functionality. Per bug report by Alvar Freude:
http://archives.postgresql.org/pgsql-bugs/2003-12/msg00022.php
2003-12-07 04:11:26 +00:00
Tom Lane
7af352f103 Brand 7.3.5. REL7_3_5 2003-12-02 16:26:00 +00:00
Tom Lane
3299a092e2 Update release notes for 7.3.5. 2003-12-02 16:15:47 +00:00
Tom Lane
8d802d4edf Force zero_damaged_pages to be effectively ON during recovery from WAL,
since there is no need to worry about damaged pages when we are going to
overwrite them anyway from the WAL.  Per recent discussion.
2003-12-01 16:53:42 +00:00
Tom Lane
6144601f42 Back-patch fix to check vartypmod when matching PlannerParamVar entries.
This should prevent some obscure cases of 'variable not in subplan target
lists', although actual failures have only been reported against 7.4 in
which the bug is much easier to trigger.
2003-11-30 22:24:16 +00:00
Tom Lane
a0547f6ea2 Back-patch fix to cause stats processes to detach from shared memory,
so that they do not prevent the postmaster from deleting the shmem segment
during crash recovery.
2003-11-30 21:56:36 +00:00
Joe Conway
8582f21afd Make PQescapeBytea and byteaout consistent with each other, and
octal escape all octets outside the range 0x20 to 0x7e. This fixes
the problem pointed out by Sergey Yatskevich here:
http://archives.postgresql.org/pgsql-bugs/2003-11/msg00140.php
2003-11-30 20:52:37 +00:00
Joe Conway
005887d1c0 Added missing SPI_finish() calls to get_tuple_of_interest(). Fixes bug
reported by Andrea Grassi.
2003-11-26 20:44:54 +00:00
Tom Lane
fe979ae406 Back-patch removal of unnecessary inclusion of <crypt.h>, so that
7.3.5 will build out-of-the-box on Solaris.
2003-10-31 18:14:11 +00:00
Jan Wieck
dde926bfe0 Moved the recently added test for foreign key disabled by rewrite
rule into the rule.sql since it affects the latter if run in paralell.

Jan
2003-10-31 14:27:51 +00:00
Jan Wieck
d1c496e9d5 Fix for possible referential integrity violation when a qualified ON INSERT
rule split the query into one INSERT and one UPDATE where the UPDATE
then hit's the just created row without modifying the key fields again.
In this special case, the new key slipped in totally unchecked.

Jan
2003-10-31 03:57:42 +00:00
Jan Wieck
9e692f2307 Support for qualified type names in PL/Tcl's spi_prepare command.
This is not 100% backward compatible as formerly a double quoted
type name containing a dot could be used. But I don't think may people
use dot's in the name of user defined types.

Jan
2003-10-30 02:00:44 +00:00
Tom Lane
0847c879a9 Don't choke when the handler for a procedural language is located in
the pg_catalog schema.  Per bug report some months back from Jochem van Dieten.
2003-10-28 21:05:39 +00:00
Tom Lane
98c7f157f2 It is possible for ResolveNew to be used to insert a sublink into a
subquery that didn't previously have one.  We have traditionally made
the caller of ResolveNew responsible for updating the hasSubLinks flag
of the outermost query, but this fails to account for hasSubLinks in
subqueries.  Fix ResolveNew to handle this.  We might later want to
change the calling convention of ResolveNew so that it can fix the
outer query too, simplifying callers.  But I went with the localized
fix for now.  Per bug report from J Smith, 20-Oct-03.
2003-10-20 20:02:30 +00:00
Tom Lane
f8ee74faeb When dumping CREATE INDEX, must show opclass name if the opclass isn't
in the schema search path.  Otherwise pg_dump doesn't correctly dump
scenarios where a custom opclass is created in 'public' and then used
by indexes in other schemas.
2003-10-02 22:25:08 +00:00
Bruce Momjian
243f11ccf1 [ Patch applied only to 7.3.X.]
Hi There's a bug in the clusterdb script where it looks like the arguments
to the psql command are being passed in the wrong order, so it fails when
you run it on a database that is not on localhost.
Here's the output from the command:

133 anands-Computer:bin/scripts> clusterdb -h wooster -U rr granada
psql: warning: extra option wooster ignored
psql: warning: extra option -U ignored
psql: warning: extra option rr ignored
psql: warning: extra option -F: ignored
psql: warning: extra option -P ignored
psql: warning: extra option format=unaligned ignored
psql: warning: extra option -t ignored
psql: warning: extra option -c ignored
psql: warning: extra option SELECT nspname, pg_class.relname,
pg_class_2.relname FROM pg_class, pg_class AS pg_class_2 JOIN pg_namespace
ON (pg_namespace.oid=relnamespace), pg_index WHERE
pg_class.oid=pg_index.indrelid AND pg_class_2.oid=pg_index.indexrelid AND
pg_index.indisclustered AND pg_class.relowner=(SELECT usesysid FROM
pg_user WHERE usename=current_user) ignored
psql: FATAL:  user "-h" does not exist



I'm attaching a patch that fixes the problem. The diff was run on
postgresql 7.3.4

Thanks a lot.
Anand Ranganathan
2003-09-29 18:53:08 +00:00
Jan Wieck
6518b4cdf7 Backpatched changes for rules when casts are dumped according to
discussion on hackers.


Jan
2003-09-28 17:46:19 +00:00
Tom Lane
57040f5069 _SPI_cursor_operation forgot to check for failure return from
_SPI_begin_call.  Per gripe from Tomasz Myrta.
2003-09-23 15:11:41 +00:00
Tom Lane
5f2b17e617 Back-patch fix for plpython problems with dropped table columns;
per bug report from Arthur Ward, who also tested this patch.
2003-09-17 18:40:11 +00:00
Tom Lane
64b9dfa56f Back-patch the other part of Karel's formatting bug fix. 2003-09-03 19:01:35 +00:00
Tom Lane
e6d6713ceb Repair problems with to_char() overrunning its input string.
From Karel Zak.
2003-09-03 15:00:07 +00:00