Barry Lind [Sat, 5 Jan 2002 22:26:23 +0000 (22:26 +0000)]
Bugfix for bug reported by Marcus Better (marcus@dactylis.com). When preforming
a get on a bytea value the code was running the raw value from the server
through character set conversion, which if the character set was SQL_ASCII
would cause all 8bit characters to become ?'s.
Bruce Momjian [Fri, 4 Jan 2002 21:32:28 +0000 (21:32 +0000)]
Re-order items:
> * Consider use of open/fctl(O_DIRECT) to minimize OS caching
> * Make blind writes go through the file descriptor cache 391d392
< * Make blind writes go through the file descriptor cache 409d409
< * Consider use of open/fctl(O_DIRECT) to minimize OS caching
Add more complete details on date/time keywords and parsing rules.
Move some tabular information on these from the chapter on data types to
the appendix on dates and times.
Have to_date() call timestamptz_date() per Karel's email instructions.
Fixes time zone problems introduced by Thomas' implementation of
TIMESTAMP WITHOUT TIME ZONE which caused the behavior of the previously
appropriate routine, timestamp_date(), to change for the worse in this
context.
Tom Lane [Thu, 3 Jan 2002 23:21:32 +0000 (23:21 +0000)]
Require ownership permission for CREATE INDEX, per bug report.
Disallow CREATE INDEX on system catalogs, non-tables (views, sequences, etc).
Disallow CREATE/DROP TRIGGER on system catalogs, non-tables.
Disallow ALTER TABLE ADD/DROP CONSTRAINT on system catalogs.
Disallow FOREIGN KEY reference to non-table.
None of these things can actually work in the present system structure,
but the code was letting them pass without complaint.
Tom Lane [Thu, 3 Jan 2002 21:52:05 +0000 (21:52 +0000)]
Instead of waiting a fixed amount of time for the test postmaster to
start up, wait until a psql connection attempt succeeds. Per gripe
from Jason Tishler.
Bruce Momjian [Thu, 3 Jan 2002 07:21:48 +0000 (07:21 +0000)]
> > On Fri, Dec 21, 2001 at 11:43:21AM +0800, Christopher Kings-Lynne
wrote:
> > > Just testing pgcrypto on freebsd/alpha. I get some warnings:
> > They should be harmless, although I should fix them.
>
> The actual code is:
>
> if ((dlen & 15) || (((unsigned) res) & 3))
> return -1;
> Hard to imagine how (uint *) & 3 makes any sense, unless res isn't
> always a (uint8 *). Is that true?
At some point it was casted to (uint32*) so I wanted to be sure its ok.
ATM its pointless. Please apply the following patch.
Tom Lane [Wed, 2 Jan 2002 22:09:23 +0000 (22:09 +0000)]
Fix to_timestamp/to_date so that zero year input for Y, YY, or YYY
formats will be taken as 2000, not year zero. Per bug report from
Aasmund Midttun Godal. Fix from Karel Zak.
Tom Lane [Wed, 2 Jan 2002 00:41:26 +0000 (00:41 +0000)]
Fix incorrect description of rowtype variable declarations. Eventually
(IMHO) the code should be fixed to do what the documentation formerly
claimed, and then revert this change.
Tom Lane [Tue, 1 Jan 2002 23:16:22 +0000 (23:16 +0000)]
Do not accept interrupts in RESUME_INTERRUPTS() and END_CRIT_SECTION()
macros, but only at explicit CHECK_FOR_INTERRUPTS() calls. Not clear
whether overenthusiastic acceptance of interrupts accounts for any real
bugs, but it definitely seems risky and unnecessary.
Tom Lane [Tue, 1 Jan 2002 20:32:37 +0000 (20:32 +0000)]
Fix race condition that could allow two concurrent transactions
to insert the same key into a supposedly unique index. The bug is of
low probability, and may not explain any of the recent reports of
duplicated rows; but a bug is a bug.
Tom Lane [Sun, 30 Dec 2001 23:09:42 +0000 (23:09 +0000)]
Make sure that all <ctype.h> routines are called with unsigned char
values; it's not portable to call them with signed chars. I recall doing
this for the last release, but a few more uncasted calls have snuck in.
Document the precision arguments for date/time types per SQL9x.
Update the list of recognized time zones.
Document the range of arguments allowed for SET TIME ZONE.
Still need to add info on other date/time symbols (e.g. "AM", "T")
and to freshen the docs on the date/time parsing rules.
Rework the date/time parsing to tighten up some cases and to enable other
cases which should have worked but did not.
Now supports julian day (J2452271), ISO time labels (T040506) and various
combinations of spaces and run-togethers of dates, times, and time zones.
All regression tests pass, and I have more tests to add after the 7.2
release (don't want to require changes to the ancillary horology result
files until after then).
Tom Lane [Fri, 28 Dec 2001 18:16:43 +0000 (18:16 +0000)]
Ensure that all direct uses of spinlock-protected data structures use
'volatile' pointers to access those structures, so that optimizing
compilers will not decide to move the structure accesses outside of the
spinlock-acquire-to-spinlock-release sequence. There are no known bugs
in these uses at present, but based on bad experience with lwlock.c,
it seems prudent to ensure that we protect these other uses too.
Per pghackers discussion around 12-Dec. (Note: it should not be
necessary to worry about structures protected by LWLocks, since the
LWLock acquire and release operations are not inline macros.)
Bruce Momjian [Fri, 28 Dec 2001 04:57:55 +0000 (04:57 +0000)]
Added for Christof Petig:
< o Allow SELECT of array of strings into a auto-sized variable
---
> o -Allow SELECT of array of strings into a auto-sized variable
> o auto allocation for indicator variable arrays (int *ind_p=NULL)
> o auto allocation for string arrays (char **foo_pp=NULL)
> o ECPGfree_auto_mem fixed
> o all function names with external linkage are now prefixed by ECPG
Bruce Momjian [Fri, 28 Dec 2001 04:30:18 +0000 (04:30 +0000)]
Update to show current capability and future direction, from Peter:
> * -Allow secure single-user access without passwords using Unix socket permissions
> * Make single-user local socket access permissions the default (Peter E)