aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2004-01-07 23:03:06 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2004-01-07 23:03:06 +0000
commit4f913efe7372935923e4828fed7454bf1c3c6469 (patch)
tree7657aa0f70170c83368e2173dea460d6cea1fa2e /src
parentcad5f4a8c4331153de9476a3dacd22577e358c39 (diff)
downloadpostgresql-4f913efe7372935923e4828fed7454bf1c3c6469.tar.gz
postgresql-4f913efe7372935923e4828fed7454bf1c3c6469.zip
make
Diffstat (limited to 'src')
-rw-r--r--src/backend/utils/init/miscinit.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/utils/init/miscinit.c b/src/backend/utils/init/miscinit.c
index a64d6942391..82a6d277729 100644
--- a/src/backend/utils/init/miscinit.c
+++ b/src/backend/utils/init/miscinit.c
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/utils/init/miscinit.c,v 1.117 2003/11/29 19:52:01 pgsql Exp $
+ * $PostgreSQL: pgsql/src/backend/utils/init/miscinit.c,v 1.118 2004/01/07 23:03:06 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -508,7 +508,7 @@ CreateLockFile(const char *filename, bool amPostmaster,
errmsg("could not open lock file \"%s\": %m",
filename)));
}
- if ((len = read(fd, buffer, sizeof(buffer) - 1)) <= 0)
+ if ((len = read(fd, buffer, sizeof(buffer) - 1)) < 0)
ereport(FATAL,
(errcode_for_file_access(),
errmsg("could not read lock file \"%s\": %m",
@@ -728,7 +728,7 @@ RecordSharedMemoryInLockFile(unsigned long id1, unsigned long id2)
return;
}
len = read(fd, buffer, sizeof(buffer) - 100);
- if (len <= 0)
+ if (len < 0)
{
ereport(LOG,
(errcode_for_file_access(),