Commit Graph

16965 Commits

Author SHA1 Message Date
Bruce Momjian 9dac52649d Win32 adjustments for dirmod and configure/configure.in. 2004-02-02 22:20:33 +00:00
Tom Lane 67aa1962b7 autoconf run. 2004-02-02 18:35:45 +00:00
Bruce Momjian 011ad7efec Set only LC_ALL for sort in tags creation. 2004-02-02 17:29:32 +00:00
Bruce Momjian bd2a8078d3 > src/backend/commands/user.c file has some parse error at repalloc(),
palloc()$

Fixed.  Thanks.

> src/backend/postmaster/pgstat.c miss
> #include "tcop/tcopprot.h" line.

Fixed.

> src/utils/dllinit.c wrong include header line at MinGW.
> #include <cygwin/version.h> must be not included

Fixed.

> by the way,
> I can't compile eccp because I used lower version bison.

> and bin/pg_resetxlog too. in this case I can't find what's wrong.

Fixed.
2004-02-02 17:21:08 +00:00
Neil Conway 9e218af7ed Fix a read of uninitialized memory in next_token() of hba.c, spotted via
valgrind: a buffer passed to strncmp() had to be NUL-terminated. Original
report and patch from Dennis Bjorkland, some cleanup by Andrew Dunstan,
and finally some editorializing from Neil Conway.
2004-02-02 16:58:30 +00:00
Bruce Momjian 4c29e21578 Adjustments for Win32-specific rename code, and add include file. 2004-02-02 16:37:46 +00:00
Bruce Momjian 98a5284170 Move win32 changes from configure to configure.in, per Tom, autoconf
run.
2004-02-02 16:00:49 +00:00
Tom Lane 6f295328e5 Do not let external specification of CFLAGS stop us from adding
-fno-strict-aliasing.
2004-02-02 04:07:18 +00:00
Tom Lane 9fe097577e 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:08 +00:00
Neil Conway b8362d465d Use Tcl_PutEnv() in place of putenv() in libpgtcl, as the latter can
apparently corrupt the Tcl runtime. Per suggestion from Michael
Brusser <michael@synchronicity.com>
2004-02-02 00:35:08 +00:00
Bruce Momjian d9d2ca8e8e Adjust rename on Win32 to only link to temp name while holding lock,
then release locks and loop over renaming to active file name.
2004-02-02 00:17:23 +00:00
Bruce Momjian e5e5a323ca Briefly,
* configure + Makefile changes
 * shared memory attaching in EXEC_BACKEND case (+ minor fix for apparent
cygwin bug under cygwin/EXEC_BACKEND case only)
 * PATH env var separator differences
 * missing win32 rand functions added
 * placeholder replacements for sync etc under port.h


To those who are really interested, and there are a few of you: the attached
patch + file will allow the source base to be compiled (and, for some
definition, "run") under MingW, with the following caveats (I wanted to
first properly fix all but the last of these, but y'all won't quit asking
for a patch :-):

        * child death: SIGCHLD not yet sent, so as a minimum, you'll need to
put in some sort of delay after StartupDatabase, and handle setting
StartupPID to 0 etc (ie. the stuff the reaper() signal function is supposed
to do)

        * dirmod.c: comment out the elog calls

        * dfmgr.c: some hackage required to substitute_libpath_macro

        * slru/xact.c: comment out the errno checking after the readdir
(fixed by next version of MingW)

Again, this is only if you *really* want to see postgres compile and start,
and is a nice leg-up for working on the other Win32 TODO list items. Just
don't expect too much else from it at this point...


Claudio Natoli
2004-02-02 00:11:31 +00:00
Bruce Momjian 10bb17e334 Set locale to C before doing sort in make_ctags. 2004-02-01 23:11:33 +00:00
Tom Lane e1826d037a Update char_length() example for new semantics. 2004-02-01 06:55:07 +00:00
Tom Lane f27976c85b Make length() disregard trailing spaces in char(n) values, per discussion
some time ago and recent patch from Gavin Sherry.  Update documentation
to point out that trailing spaces are insignificant in char(n).
2004-02-01 06:27:48 +00:00
Neil Conway 08b0e60563 Fix a probably-harmless read of uninitialized memory in mkdir_p(), to
silence a valgrind warning.
2004-01-31 22:10:00 +00:00
Neil Conway 25b8b69eec Remove a superfluous semi-colon. 2004-01-31 21:18:00 +00:00
Neil Conway 7b2cf1713d Micro-opt: replace calls like
appendStringInfo(buf, "%s", str);
with
    appendStringInfoString(buf, str);
as the latter form is slightly faster.
2004-01-31 05:09:41 +00:00
Tom Lane d4fd7d85f3 Fix text_position to not scan past end of source string in multibyte
case, per report from Korea PostgreSQL Users' Group.  Also do some
cosmetic cleanup in nearby code.
2004-01-31 00:45:21 +00:00
Tom Lane a3c969d522 Fix debug elog message to agree with name of its routine. 2004-01-30 22:44:21 +00:00
Bruce Momjian 5ee2ae2049 Remove sleep() and use single PG_SLEEP call for Win32 signal handling
and consistency.

Change PG_USLEEP to use SleepEx() for signal interuptability.
2004-01-30 15:57:04 +00:00
Bruce Momjian 777babeced Add:
<
> * Allow libpq to return information about prepared queries
2004-01-30 11:11:07 +00:00
Neil Conway 940b87e722 Fix (debatable) spelling mistake in a comment: 'concatenate' is the usual
term, not 'catenate'.
2004-01-29 12:34:59 +00:00
Tom Lane 18f9d7c74e Make USING and WITH optional to bring the syntax of \copy into exact
agreement with what the backend grammar actually accepts (which is a
bit looser than what its documentation claims).  Per report from Bill
Moran, though I did not use his patch since it removed all the
undocumented flexibility that the code historically had and the backend
still has.
2004-01-28 22:14:04 +00:00
Tom Lane 2f0d43b251 Review uses of IsUnderPostmaster, change some tests to look at
whereToSendOutput instead because they are really inquiring about
the correct client communication protocol.  Update some comments.
This is pointing towards supporting regular FE/BE client protocol
in a standalone backend, per discussion a month or so back.
2004-01-28 21:02:40 +00:00
Tom Lane b3ead7c045 Fix typo. 2004-01-28 20:43:03 +00:00
Michael Meskes 6d9a81b66f Removed some debugging output. 2004-01-28 09:54:23 +00:00
Michael Meskes 6ccfc4f430 - Issue a warning if a cursor is declared but not opened.
- Fixed prototype for ECPGprepared_statement to not moan about "const char"
- Fixed parsing of nested structures.
- Added option to parse header files.
2004-01-28 09:52:14 +00:00
Tom Lane 31a0f1d33b Fix oversight in check_ungrouped_columns optimization that avoids
unnecessary checks for complex grouping expressions: we cannot check
whether the expressions are simple Vars until after we apply
flatten_join_alias_vars, because in the case of FULL JOIN that routine
can introduce non-Var expressions.  Per example from Joel Knight.
2004-01-28 07:46:44 +00:00
Tom Lane 4405b3e05e simplify_function() mustn't try to evaluate functions that return
composite types, because TupleTableSlots aren't Datums and can't be
stored in Const nodes.  We can remove this restriction if we ever
adopt a cleaner runtime representation for whole-tuple results, but
at the moment it's broken.  Per example from Thomas Hallgren.
2004-01-28 00:05:04 +00:00
Neil Conway 45842e6c52 Improve the documentation of the 'join_collapse_limit' GUC var. Thanks to
Tom Lane for some editorial suggestions.
2004-01-27 16:51:43 +00:00
Tom Lane 7e34b2d73f Run stats test separately, not as part of a parallel group, to avoid
possible failures due to stats collector not updating fast enough under
heavy load.  Per report from Jeremy Yoder.
2004-01-27 00:50:33 +00:00
Bruce Momjian 70d5811514 Pgindent win32 signal code. 2004-01-27 00:46:58 +00:00
Bruce Momjian 50491963cb Here's the latest win32 signals code, this time in the form of a patch
against the latest shapshot. It also includes the replacement of kill()
with pqkill() and sigsetmask() with pqsigsetmask().

Passes all tests fine on my linux machine once applied. Still doesn't
link completely on Win32 - there are a few things still required. But
much closer than before.

At Bruce's request, I'm goint to write up a README file about the method
of signals delivery chosen and why the others were rejected (basically a
summary of the mailinglist discussions). I'll finish that up once/if the
patch is accepted.


Magnus Hagander
2004-01-27 00:45:26 +00:00
Bruce Momjian eec08b95e7 [all] Removed call to getppid in SendPostmasterSignal, replacing with a
PostmasterPid variable, which gets set (early) in PostmasterMain
getppid would not be the postmaster?

[fork/exec] Implements processCancelRequest by keeping an array of

pid/cancel_key structs in shared mem

[fork/exec] Moves AttachSharedMemoryAndSemaphores call for backends into
SubPostmasterMain

[win32] Implements reaper/waitpid by keeping an arrays of children
pids,handles in postmaster local mem
      - this item is largely untested, for reasons which should be
obvious, but appears sound

[win32/all] Added extern for pgpipe in Win32 case, and changed the second
pipe call (which seems to have been missed earlier) to pgpipe

[win32] #define'd ftruncate to chsize in the Win32 case

[win32] PG_USLEEP for Win32 has a misplaced paren. Fixed.

[win32] DLLIMPORT handling for MingW case


Claudio Natoli
2004-01-26 22:59:54 +00:00
Bruce Momjian ede3b762a3 Back out win32 patch so we can apply it separately. 2004-01-26 22:54:58 +00:00
Bruce Momjian f4921e5ca3 Attached is a patch that fixes some trivial typos and alignment. Please
apply.

Alvaro Herrera
2004-01-26 22:51:56 +00:00
Bruce Momjian af29187f2e Add Name:
> * -Add checks for fclose() failure (Tom)
2004-01-26 22:38:42 +00:00
Bruce Momjian ee96c82cc2 Done:
> * -Add checks for fclose() failure (Tom)
2004-01-26 22:38:10 +00:00
Tom Lane c77f363384 Ensure that close() and fclose() are checked for errors, at least in
cases involving writes.  Per recent discussion about the possibility
of close-time failures on some filesystems.  There is a TODO item for
this, too.
2004-01-26 22:35:32 +00:00
Neil Conway e0707cbae9 The attached patch clarifies (or, rather, makes explicit) to readers how
to handle memory management for char pointers returned by libpq functions.
Original patch by Gavin Sherry, some tweaking and consistency improvements
by Neil Conway.
2004-01-26 22:13:21 +00:00
Tom Lane be11fa26e3 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:15:59 +00:00
Bruce Momjian 7a14a72e08 Added:
> * Dump large object comments in custom dump format
2004-01-26 18:32:08 +00:00
Neil Conway f30d39e706 Add usage examples for PREPARE and EXECUTE. Original patch from Gavin
Sherry, editorializing by Neil Conway.
2004-01-26 17:26:31 +00:00
Teodor Sigaev 146aab497e Docs fix from Kris Jurka <books@ejurka.com> 2004-01-26 15:08:52 +00:00
Bruce Momjian ee2f149d30 Clarify that the 'user' column still applies for 'trust'. 2004-01-26 05:35:15 +00:00
Bruce Momjian 3761f968c8 Update datestamp. 2004-01-26 05:33:24 +00:00
Neil Conway 11c7bdb4e4 Fix an obsolete file path mentioned in a comment. 2004-01-25 22:19:42 +00:00
Bruce Momjian 34f0a8e72d *** empty log message *** 2004-01-25 04:56:25 +00:00
Bruce Momjian ccf3a0440a Add Joe to TODO:
> * Joe is Joe Conway <mail@joeconway.com>
2004-01-25 04:50:16 +00:00