*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/access/heap/heapam.c,v 1.205 2005/11/26 05:03:06 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/access/heap/heapam.c,v 1.206 2006/01/11 08:43:11 neilc Exp $
*
*
* INTERFACE ROUTINES
recptr = XLogInsert(RM_HEAP_ID, XLOG_HEAP_CLEAN, rdata);
- return (recptr);
+ return recptr;
}
static XLogRecPtr
recptr = XLogInsert(RM_HEAP_ID, info, rdata);
- return (recptr);
+ return recptr;
}
XLogRecPtr
log_heap_move(Relation reln, Buffer oldbuf, ItemPointerData from,
Buffer newbuf, HeapTuple newtup)
{
- return (log_heap_update(reln, oldbuf, from, newbuf, newtup, true));
+ return log_heap_update(reln, oldbuf, from, newbuf, newtup, true);
}
static void
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/access/heap/tuptoaster.c,v 1.57 2005/12/03 05:50:59 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/access/heap/tuptoaster.c,v 1.58 2006/01/11 08:43:11 neilc Exp $
*
*
* INTERFACE ROUTINES
if (VARATT_IS_EXTERNAL(attr))
{
/* fast path */
- return (toast_fetch_datum_slice(attr, sliceoffset, slicelength));
+ return toast_fetch_datum_slice(attr, sliceoffset, slicelength);
}
else
preslice = attr;
VARATT_SIZEP(result) |= VARATT_FLAG_COMPRESSED;
if (length == 0)
- return (result); /* Can save a lot of work at this point! */
+ return result; /* Can save a lot of work at this point! */
startchunk = sliceoffset / TOAST_MAX_CHUNK_SIZE;
endchunk = (sliceoffset + length - 1) / TOAST_MAX_CHUNK_SIZE;
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/access/nbtree/nbtinsert.c,v 1.129 2005/11/22 18:17:06 momjian Exp $
+ * $PostgreSQL: pgsql/src/backend/access/nbtree/nbtinsert.c,v 1.130 2006/01/11 08:43:11 neilc Exp $
*
*-------------------------------------------------------------------------
*/
/* write and let go of metapage buffer */
_bt_wrtbuf(rel, metabuf);
- return (rootbuf);
+ return rootbuf;
}
/*
* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/backend/access/transam/xlog.c,v 1.225 2005/12/29 18:08:05 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/access/transam/xlog.c,v 1.226 2006/01/11 08:43:12 neilc Exp $
*
*-------------------------------------------------------------------------
*/
{
RecPtr.xlogid = 0;
RecPtr.xrecoff = SizeOfXLogLongPHD; /* start of 1st chkpt record */
- return (RecPtr);
+ return RecPtr;
}
/*
END_CRIT_SECTION();
- return (RecPtr);
+ return RecPtr;
}
/*
path, log, seg)));
}
else
- return (fd);
+ return fd;
}
/*
errmsg("could not open file \"%s\" (log file %u, segment %u): %m",
path, log, seg)));
- return (fd);
+ return fd;
}
/*
* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/backend/access/transam/xlogutils.c,v 1.39 2005/10/15 02:49:11 momjian Exp $
+ * $PostgreSQL: pgsql/src/backend/access/transam/xlogutils.c,v 1.40 2006/01/11 08:43:12 neilc Exp $
*
*-------------------------------------------------------------------------
*/
}
if (buffer != InvalidBuffer)
LockBuffer(buffer, BUFFER_LOCK_EXCLUSIVE);
- return (buffer);
+ return buffer;
}
buffer = ReadBuffer(reln, blkno);
if (buffer != InvalidBuffer)
LockBuffer(buffer, BUFFER_LOCK_EXCLUSIVE);
- return (buffer);
+ return buffer;
}
if (_xlast < _xlcnt)
{
_xlrelarr[_xlast].reldata.rd_rel = &(_xlpgcarr[_xlast]);
- return (&(_xlrelarr[_xlast]));
+ return &(_xlrelarr[_xlast]);
}
/* reuse */
_xl_remove_hash_entry(res);
_xlast--;
- return (res);
+ return res;
}
_xlrelarr[0].lessRecently = res;
res->lessRecently->moreRecently = res;
- return (&(res->reldata));
+ return &(res->reldata);
}
/*
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/executor/execMain.c,v 1.263 2006/01/07 22:30:43 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/executor/execMain.c,v 1.264 2006/01/11 08:43:12 neilc Exp $
*
*-------------------------------------------------------------------------
*/
default:
elog(ERROR, "unrecognized heap_lock_tuple status: %u",
test);
- return (NULL);
+ return NULL;
}
}
}
epq->rti = 0;
estate->es_useEvalPlan = false;
/* and continue Query execution */
- return (NULL);
+ return NULL;
}
Assert(oldepq->rti != 0);
/* push current PQ to freePQ stack */
goto lpqnext;
}
- return (slot);
+ return slot;
}
static void
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/libpq/be-secure.c,v 1.60 2005/11/22 18:17:11 momjian Exp $
+ * $PostgreSQL: pgsql/src/backend/libpq/be-secure.c,v 1.61 2006/01/11 08:43:12 neilc Exp $
*
* Since the server static private key ($DataDir/server.key)
* will normally be stored unencrypted so that the database
SSL_set_bio(s, bio, bio);
ret = 1;
err:
- return (ret);
+ return ret;
}
/*
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/utils/adt/like.c,v 1.62 2005/10/15 02:49:28 momjian Exp $
+ * $PostgreSQL: pgsql/src/backend/utils/adt/like.c,v 1.63 2006/01/11 08:43:12 neilc Exp $
*
*-------------------------------------------------------------------------
*/
/* Optimization: quickly compare the first byte. */
if (*p1 != *p2)
- return (0);
+ return 0;
p1_len = pg_mblen(p1);
if (pg_mblen(p2) != p1_len)
- return (0);
+ return 0;
/* They are the same length */
while (p1_len--)
{
if (*p1++ != *p2++)
- return (0);
+ return 0;
}
- return (1);
+ return 1;
}
/*--------------------
* different characters
*/
else if ((unsigned char) *p1 < CHARMAX || (unsigned char) *p2 < CHARMAX)
- return (0);
+ return 0;
/*
* ok, p1 and p2 are both > CHARMAX, then they must be multibyte
/*
* PostgreSQL type definitions for MAC addresses.
*
- * $PostgreSQL: pgsql/src/backend/utils/adt/mac.c,v 1.35 2005/10/15 02:49:28 momjian Exp $
+ * $PostgreSQL: pgsql/src/backend/utils/adt/mac.c,v 1.36 2006/01/11 08:43:12 neilc Exp $
*/
#include "postgres.h"
result = DirectFunctionCall1(macaddr_in, CStringGetDatum(str));
- return (result);
+ return result;
}
/*
/*
* PostgreSQL type definitions for the INET and CIDR types.
*
- * $PostgreSQL: pgsql/src/backend/utils/adt/network.c,v 1.57 2005/12/25 02:14:17 momjian Exp $
+ * $PostgreSQL: pgsql/src/backend/utils/adt/network.c,v 1.58 2006/01/11 08:43:12 neilc Exp $
*
* Jon Postel RIP 16 Oct 1998
*/
b = n / 8;
x = memcmp(l, r, b);
if (x)
- return (x);
+ return x;
lb = ((const u_char *) l)[b];
rb = ((const u_char *) r)[b];
* Encoding names and routines for work with it. All
* in this file is shared bedween FE and BE.
*
- * $PostgreSQL: pgsql/src/backend/utils/mb/encnames.c,v 1.26 2005/10/15 02:49:33 momjian Exp $
+ * $PostgreSQL: pgsql/src/backend/utils/mb/encnames.c,v 1.27 2006/01/11 08:43:12 neilc Exp $
*/
#ifdef FRONTEND
#include "postgres_fe.h"
pg_encname *p = NULL;
if (!s)
- return (-1);
+ return -1;
p = pg_char_to_encname_struct(s);
return p ? p->encoding : -1;
* (currently mule internal code (mic) is used)
* Tatsuo Ishii
*
- * $PostgreSQL: pgsql/src/backend/utils/mb/mbutils.c,v 1.53 2006/01/11 06:59:22 neilc Exp $
+ * $PostgreSQL: pgsql/src/backend/utils/mb/mbutils.c,v 1.54 2006/01/11 08:43:12 neilc Exp $
*/
#include "postgres.h"
MemoryContext oldcontext;
if (!PG_VALID_FE_ENCODING(encoding))
- return (-1);
+ return -1;
/* Can't do anything during startup, per notes above */
if (!backend_startup_complete)
pg_get_client_encoding(void)
{
Assert(ClientEncoding);
- return (ClientEncoding->encoding);
+ return ClientEncoding->encoding;
}
/*
pg_get_client_encoding_name(void)
{
Assert(ClientEncoding);
- return (ClientEncoding->name);
+ return ClientEncoding->name;
}
/*
mbstr += pg_mblen(mbstr);
len++;
}
- return (len);
+ return len;
}
/* returns the length (counted in wchars) of a multibyte string
mbstr += l;
len++;
}
- return (len);
+ return len;
}
/*
len -= l;
mbstr += l;
}
- return (clen);
+ return clen;
}
/*
len -= l;
mbstr += l;
}
- return (clen);
+ return clen;
}
void
GetDatabaseEncoding(void)
{
Assert(DatabaseEncoding);
- return (DatabaseEncoding->encoding);
+ return DatabaseEncoding->encoding;
}
const char *
GetDatabaseEncodingName(void)
{
Assert(DatabaseEncoding);
- return (DatabaseEncoding->name);
+ return DatabaseEncoding->name;
}
Datum
*
* Copyright (c) 2000-2005, PostgreSQL Global Development Group
*
- * $PostgreSQL: pgsql/src/bin/psql/tab-complete.c,v 1.143 2005/12/18 02:17:16 petere Exp $
+ * $PostgreSQL: pgsql/src/bin/psql/tab-complete.c,v 1.144 2006/01/11 08:43:12 neilc Exp $
*/
/*----------------------------------------------------------------------
casesensitive = false;
list_index = 0;
state++;
- return (complete_from_list(text, state));
+ return complete_from_list(text, state);
}
/* If no more matches, return null. */
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/interfaces/libpq/fe-connect.c,v 1.324 2005/11/22 18:17:32 momjian Exp $
+ * $PostgreSQL: pgsql/src/interfaces/libpq/fe-connect.c,v 1.325 2006/01/11 08:43:13 neilc Exp $
*
*-------------------------------------------------------------------------
*/
status = 0; /* everything is ok */
}
PQclear(res);
- return (status);
+ return status;
}
PGVerbosity
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/interfaces/libpq/fe-exec.c,v 1.177 2005/11/22 18:17:32 momjian Exp $
+ * $PostgreSQL: pgsql/src/interfaces/libpq/fe-exec.c,v 1.178 2006/01/11 08:43:13 neilc Exp $
*
*-------------------------------------------------------------------------
*/
/* early out if the socket is already in the state requested */
if (barg == conn->nonblocking)
- return (0);
+ return 0;
/*
* to guarantee constancy for flushing/query/result-polling behavior we
*/
/* if we are going from blocking to non-blocking flush here */
if (pqFlush(conn))
- return (-1);
+ return -1;
conn->nonblocking = barg;
- return (0);
+ return 0;
}
/*
int
PQisnonblocking(const PGconn *conn)
{
- return (pqIsnonblocking(conn));
+ return pqIsnonblocking(conn);
}
/* try to force data out, really only useful for non-blocking users */
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/interfaces/libpq/fe-misc.c,v 1.123 2005/11/22 18:17:33 momjian Exp $
+ * $PostgreSQL: pgsql/src/interfaces/libpq/fe-misc.c,v 1.124 2006/01/11 08:43:13 neilc Exp $
*
*-------------------------------------------------------------------------
*/
int
PQmblen(const char *s, int encoding)
{
- return (pg_encoding_mblen(encoding, s));
+ return pg_encoding_mblen(encoding, s);
}
/*
int
PQdsplen(const char *s, int encoding)
{
- return (pg_encoding_dsplen(encoding, s));
+ return pg_encoding_dsplen(encoding, s);
}
/*
str = getenv("PGCLIENTENCODING");
if (str && *str != '\0')
encoding = pg_char_to_encoding(str);
- return (encoding);
+ return encoding;
}
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/interfaces/libpq/fe-protocol2.c,v 1.20 2005/11/22 18:17:33 momjian Exp $
+ * $PostgreSQL: pgsql/src/interfaces/libpq/fe-protocol2.c,v 1.21 2006/01/11 08:43:13 neilc Exp $
*
*-------------------------------------------------------------------------
*/
* and the flush fails
*/
if (pqFlush(conn) && pqIsnonblocking(conn))
- return (1);
+ return 1;
/* non blocking connections may have to abort at this point. */
if (pqIsnonblocking(conn) && PQisBusy(conn))
- return (1);
+ return 1;
/* Return to active duty */
conn->asyncStatus = PGASYNC_BUSY;
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/interfaces/libpq/fe-protocol3.c,v 1.23 2005/11/22 18:17:33 momjian Exp $
+ * $PostgreSQL: pgsql/src/interfaces/libpq/fe-protocol3.c,v 1.24 2006/01/11 08:43:13 neilc Exp $
*
*-------------------------------------------------------------------------
*/
* and the flush fails
*/
if (pqFlush(conn) && pqIsnonblocking(conn))
- return (1);
+ return 1;
/* Return to active duty */
conn->asyncStatus = PGASYNC_BUSY;
* with the CopyDone; are there corner cases where that doesn't happen?)
*/
if (pqIsnonblocking(conn) && PQisBusy(conn))
- return (1);
+ return 1;
/* Wait for the completion response */
result = PQgetResult(conn);
salary = DatumGetInt32(GetAttributeByName(t, "salary", &isnull));
if (isnull)
- return (false);
+ return false;
return salary > limit;
}