234a02b2a8
Replace direct assignments to VARATT_SIZEP(x) with SET_VARSIZE(x, len).
...
Get rid of VARATT_SIZE and VARATT_DATA, which were simply redundant with
VARSIZE and VARDATA, and as a consequence almost no code was using the
longer names. Rename the length fields of struct varlena and various
derived structures to catch anyplace that was accessing them directly;
and clean up various places so caught. In itself this patch doesn't
change any behavior at all, but it is necessary infrastructure if we hope
to play any games with the representation of varlena headers.
Greg Stark and Tom Lane
2007-02-27 23:48:10 +00:00
16059d39a0
Replace some strncpy() by strlcpy().
2007-02-07 00:52:35 +00:00
ae643747b1
Fix a passel of recently-committed violations of the rule 'thou shalt
...
have no other gods before c.h'. Also remove some demonstrably redundant
#include lines, mostly of <errno.h> which was added to c.h years ago.
2006-07-14 05:28:29 +00:00
a0ffab351e
Magic blocks don't do us any good unless we use 'em ... so install one
...
in every shared library.
2006-05-30 22:12:16 +00:00
a323ede280
Fix a few places that were checking for the return value of palloc() to be
...
non-NULL: palloc() ereports on OOM, so we can safely assume it returns a
valid pointer.
2006-03-19 22:22:56 +00:00
1dc3498251
Standard pgindent run for 8.1.
2005-10-15 02:49:52 +00:00
b7d236d663
Make sure contrib C functions are marked strict where needed.
...
Kris Jurka
2005-01-29 22:35:02 +00:00
55b113257c
make sure the $Id tags are converted to $PostgreSQL as well ...
2003-11-29 22:41:33 +00:00
2f606ed87d
Remove another useless, counterproductive srandom() call.
2003-09-07 15:27:25 +00:00
8fd5b3ed67
Error message editing in contrib (mostly by Joe Conway --- thanks Joe!)
2003-07-24 17:52:50 +00:00
3518fbe86f
Add missing semicolons to a few PG_FUNCTION_INFO_V1 calls.
2002-10-26 15:01:01 +00:00
5f97dc3e7c
chkpass_rout returns text so change PG_RETURN_CSTRING to PG_RETURN_TEXT_P.
...
This is currently a cosmetic difference but I make the change now in case
the macros diverge one day.
2002-08-29 12:18:20 +00:00
f9d87c66db
Fix warning
2001-12-19 18:49:24 +00:00
ea08e6cd55
New pgindent run with fixes suggested by Tom. Patch manually reviewed,
...
initdb/regression tests pass.
2001-11-05 17:46:40 +00:00
b81844b173
pgindent run on all C files. Java run to follow. initdb/regression
...
tests pass.
2001-10-25 05:50:21 +00:00
8d7952fdc4
Further conversions to Version 1 API. Also, fix boolean return to use
...
PG_RETURN_BOOL(0) instead of return 0.
2001-05-30 02:11:46 +00:00
505d9037cd
Upgraded code to use the current version 1 calling conventions.
2001-05-28 15:34:27 +00:00
2bc1c14ab0
Changed use of macros for extracting information. According to comments
...
in c.h we should be using the visible structure. We should only see
de-TOASTed values in this program. The old method refused to compile
because the length macro was no longer an lvalue.
2001-05-27 19:06:20 +00:00
b95ff0c542
Initial checkin of a contributed type that handles passwords efficiently.
2001-05-03 12:32:13 +00:00