Commit Graph

19912 Commits

Author SHA1 Message Date
Bruce Momjian
0326d705ab Update Russian FAQ.
Victor Vislobokov
2005-09-28 11:33:42 +00:00
Bruce Momjian
341c3399da Backpatch to 8.0.X:
In several places PL/Python was calling PyObject_Str() and then
PyString_AsString() without checking if the former had returned
NULL to indicate an error.  PyString_AsString() doesn't expect a
NULL argument, so passing one causes a segmentation fault.  This
patch adds checks for NULL and raises errors via PLy_elog(), which
prints details of the underlying Python exception.  The patch also
adds regression tests for these checks.  All tests pass on my
Solaris 9 box running HEAD and Python 2.4.1.
2005-09-23 21:02:37 +00:00
Bruce Momjian
9516724bd7 Update FAQ's in 8.0.X branch. 2005-09-22 22:14:11 +00:00
Bruce Momjian
b3af584d7d Return proper value for psql -f filename failure if filename open fails.
Backpatch to 8.0.X.
2005-09-20 18:59:15 +00:00
Teodor Sigaev
b4d107a777 Update Snowball. I have to update it because of
old version doesn't available on Snowball's site and new version
of stemmers can't be compiled with old interface.
2005-09-15 11:56:58 +00:00
Tom Lane
8080e8e8ce Ensure that any memory leaked during an error inside the bgwriter is
recovered.  I did not see any actual leak while testing this in CVS tip,
but 8.0 definitely has a problem with leaking the space temporarily
palloc'd by BufferSync().  In any case this seems a good idea to forestall
similar problems in future.  Per report from Arjen van der Meijden.
2005-09-12 22:20:30 +00:00
Neil Conway
3926b6e9c3 Fix a mistake in the documentation for SPI_getbinval(), per Michael Fuhr. 2005-09-12 18:49:08 +00:00
Michael Meskes
39f27463b3 Fixed transaction command handling to not ignore savepoints and to correctly check for errors. 2005-09-12 11:58:33 +00:00
Tom Lane
3e711451f1 Avoid changing stdin/stdout to binary mode on Windows unless that is
really the source or destination of the archive.  I think this will
resolve recent complaints that password prompting is broken in pg_restore
on Windows.  Note that password prompting and reading from stdin is an
unworkable combination on Windows ... but that was true anyway.
2005-09-11 00:36:35 +00:00
Tom Lane
16acb8bfd3 Update regression tests for new USA timezone data. Mea culpa for not
realizing that the regression tests could be affected.
2005-09-08 16:49:18 +00:00
Tom Lane
694da2897b Update timezone data files to release 2005m of the zic database.
Among other changes, this reflects the recently passed change in USA
daylight savings rules.
2005-09-07 21:39:41 +00:00
Peter Eisentraut
57fd3d22d7 Translation update 2005-09-03 07:41:58 +00:00
Teodor Sigaev
13ff51baf2 Fix missing rows in query
update a=.. where a... with GiST index on column 'a'
2005-08-30 07:57:48 +00:00
Tom Lane
846ed05de6 Sigh, looks like you need '.set mips2' before you can access MIPS
SYNC instruction.
2005-08-29 00:41:44 +00:00
Tom Lane
9f70dce4ce Add a SYNC instruction to the S_UNLOCK sequence for MIPS. 2005-08-28 18:26:07 +00:00
Tom Lane
5677c28c91 Get the MIPS assembler syntax right. Also add a separate sync command;
the reference I consulted yesterday said SC does a SYNC, but apparently
this is not true on newer MIPS processors, so be safe.
2005-08-27 16:22:58 +00:00
Bruce Momjian
9a6f3630cf Fix typo:
sql_information_info -> sql_implementation_info

Robert Treat
2005-08-27 14:13:31 +00:00
Tom Lane
51aebb07c3 Another try at the inlined MIPS spinlock code. Can't test this myself,
but for sure it's not any more broken than the prior version.
2005-08-26 22:04:53 +00:00
Tom Lane
8c3cf25225 Back-port recent MIPS and M68K spinlock improvements to 8.0 branch. 2005-08-26 14:48:13 +00:00
Tom Lane
08e12b89d5 Back-patch fixes for problems with VACUUM destroying t_ctid chains too soon,
and with insufficient paranoia in code that follows t_ctid links.
This patch covers the 8.0 branch.
2005-08-25 19:45:06 +00:00
Michael Meskes
5576a611cd - Check for NULL before checking whether argument is an array.
- Removed stray character from string quoting.
	- Fixed check to report missing varchar pointer implementation.
2005-08-24 10:35:12 +00:00
Tom Lane
9b4296abe0 Fix broken lrand48() implementation, per Merlin Moncure. 2005-08-23 13:31:19 +00:00
Tom Lane
01bc28d48a Invoke mksafefunc and mkunsafefunc with :: decoration. This seems a good
idea on consistency grounds, whether or not it really fixes bug #1831.
Michael Fuhr
2005-08-20 19:19:31 +00:00
Tom Lane
f468542b10 Remove unnecessary configure test for inet_ntop(), per Andrew Dunstan. 2005-08-17 20:20:22 +00:00
Tom Lane
96fc1a4f77 Reject operator names >= NAMEDATALEN characters. These will not work
anyway, and in assert-enabled builds you are likely to get an assertion
failure.  Backpatch as far as 7.3; 7.2 seems not to have the problem.
2005-08-16 00:48:29 +00:00
Tom Lane
ab648632eb array_in() and array_recv() need to be more paranoid about validating
their OID parameter.  It was possible to crash the backend with
select array_in('{123}',0,0); because that would bypass the needed step
of initializing the workspace.  These seem to be the only two places
with a problem, though (record_in and record_recv don't have the issue,
and the other array functions aren't depending on user-supplied input).
Back-patch as far as 7.4; 7.3 does not have the bug.
2005-08-15 19:40:43 +00:00
Tom Lane
497f11845c int_array_enum function should be using fcinfo->flinfo->fn_extra for
working state, not fcinfo->context.  Silly oversight on my part in last
go-round of fixes.
2005-08-15 19:05:30 +00:00
Bruce Momjian
0c9f00506b This patch fixes the event type used to log output from the
stderr-in-service or output-from-syslogger-in-service code. Previously
everything was flagged as ERRORs there, which caused all instances to
log "LOG: logger shutting down" as error...

Please apply for 8.1. I'd also like it considered for 8.0 since logging
non-errors as errors can be cause for alarm amongst people who actually
look at their logs...

Magnus Hagander
2005-08-12 21:38:00 +00:00
Bruce Momjian
18b15c3946 [ backpatched to 8.0.X.]
> >> 3) I restarted the postmaster both times. I got this error
> both times.
> >> :25: ERROR:  could not load library "C:/Program
> >> Files/PostgreSQL/8.0/lib/testtrigfuncs.dll": dynamic load error
>
> > Yes. We really need to look at fixing that error message. I had
> > forgotten it completely :-(
>
> > Bruce, you think we can sneak that in after feature freeze? I would
> > call it a bugfix :-)
>
> Me too.  That's been on the radar for awhile --- please do
> send in a patch.

Here we go, that wasn't too hard :-)

Apart from adding the error handling, it does one more thing: it changes
the errormode when loading the DLLs. Previously if a DLL was broken, or
referenced other DLLs that couldn't be found, a popup dialog box would
appear on the screen. Which had to be clicked before the backend could
continue. This patch also disables the popup error message for DLL
loads.

I think this is something we should consider doing for the entire
backend - disable those popups, and say we deal with it ourselves. What
do you other win32 hackers thinnk about this?

In the meantime, this patch fixes the error msgs. Please apply for 8.1
and please consider a backpatch to 8.0.


Magnus Hagander
2005-08-12 21:23:18 +00:00
Bruce Momjian
66c2f44b85 Backpatch fseeko fix for seeking from end of file. 2005-08-12 00:29:22 +00:00
Bruce Momjian
18e615979e Backpatch new CVS home page URL. 2005-08-11 13:54:10 +00:00
Tom Lane
1c09a3c46d Fix crash when reading 'timezone = unknown' from postgresql.conf during
SIGHUP; it's not OK for an assign_hook to return a non-malloc'd string.
Problem was introduced during timezone library rewrite.
2005-08-08 23:39:14 +00:00
Tom Lane
4cf0feae2c Fix count_usable_fds() to stop trying to open files once it reaches
max_files_per_process.  Going further than that is just a waste of
cycles, and it seems that current Cygwin does not cope gracefully
with deliberately running the system out of FDs.  Per Andrew Dunstan.
2005-08-07 18:47:38 +00:00
Tom Lane
668448d6f0 rmtree() reported the wrong pathname if final rmdir failed. 2005-08-02 15:14:56 +00:00
Tom Lane
ae1d34f23a Back-port several small portability fixes to get contrib building
cleanly on AIX in the 8.0 branch.  Rocco Altier
2005-08-02 01:35:23 +00:00
Bruce Momjian
61dc3df71f Update AIX FAQ.
Chris Browne
2005-07-30 03:39:40 +00:00
Tom Lane
81f2d972a8 Back-patch fix for NOT-below-a-NOT case. 2005-07-29 21:40:26 +00:00
Neil Conway
f4bbe13491 Avoid crashing pg_dump if we can't connect to the database server, and
no database has been explicitly specified. Per gripe from Omar Kilani.
2005-07-27 05:15:03 +00:00
Tom Lane
4ee7e8213c Fix compare_fuzzy_path_costs() to behave a bit more sanely. The original
coding would ignore startup cost differences of less than 1% of the
estimated total cost; which was OK for normal planning but highly not OK
if a very small LIMIT was applied afterwards, so that startup cost becomes
the name of the game.  Instead, compare startup and total costs fuzzily
but independently.  This changes the plan selected for two queries in the
regression tests; adjust expected-output files for resulting changes in
row order.  Per reports from Dawid Kuroczko and Sam Mason.
2005-07-22 19:12:33 +00:00
Tom Lane
ea72596db5 It appears that Darwin (OS X) does not cope well with C functions that
have the same name as the containing shared library --- as best I can
tell, the compiler internally creates a function of that name, and does
not warn you about the conflict.  Fix buildfarm failure in back branches
by renaming tsearch() trigger function at the C level.
2005-07-18 21:37:23 +00:00
Tom Lane
2486a88b06 Back-patch fix for erroneous backslashing of LIKE pattern. 2005-07-18 19:18:19 +00:00
Tom Lane
183b1bf84f MemSet() must not cast its pointer argument to int32* until after it has
checked that the pointer is actually word-aligned.  Casting a non-aligned
pointer to int32* is technically illegal per the C spec, and some recent
versions of gcc actually generate bad code for the memset() when given
such a pointer.  Per report from Andrew Morrow.
2005-07-18 15:53:46 +00:00
Tom Lane
f6cb7198ed Make pg_regress accept a command-line option for the temporary installation's
port number, and use a default value for it that is dependent on the
configuration-time DEF_PGPORT.  Should make the world safe for running
parallel 'make check' in different branches.  Back-patch as far as 7.4
so that this actually is useful.
2005-07-17 18:29:13 +00:00
Tom Lane
091c97ff3b Back-patch recent changes to alter the order of -L flags inserted from
LDFLAGS versus those built into the Makefiles.  This looks like it will
fix several buildfarm failures in the back branches.
2005-07-17 04:05:49 +00:00
Tom Lane
123e25b3a3 Check for out-of-range varoattno in deparse_context_for_subplan.
I have seen this case in CVS tip due to new "physical tlist" optimization
for subqueries.  I believe it probably can't happen in existing releases,
but the check is not going to hurt anything, so backpatch to 8.0 just
in case.
2005-07-15 18:40:20 +00:00
Tom Lane
1e31942a33 Fix overenthusiastic optimization of 'x IN (SELECT DISTINCT ...)' and related
cases: we can't just consider whether the subquery's output is unique on its
own terms, we have to check whether the set of output columns we are going to
use will be unique.  Per complaint from Luca Pireddu and test case from
Michael Fuhr.
2005-07-15 17:09:50 +00:00
Tom Lane
35a0fc32f5 Fix libpq memory leak during PQreset() --- closePGconn() was not
freeing all transient state of the PGconn object.
2005-07-13 15:26:06 +00:00
Tom Lane
18e64f6c81 Fix config file lexer to not barf if postgresql.conf ends with a comment
that has no terminating newline.  Per report from maps.on at gmx.net.
2005-07-08 18:41:55 +00:00
Tom Lane
a646e4874a Make libpq_gettext save and restore errno in a Windows-compatible way.
Also, back-patch fix into back branches.
2005-07-08 15:24:53 +00:00
Bruce Momjian
75aed9f0c2 Backpatch to 8.0.X openssl portability fixes to pgcrypto. 2005-07-04 14:42:39 +00:00