Skip to content

Commit 1380921

Browse files
committed
Patch from Hiroshi for overflow btree comparison.
1 parent 3f6ff32 commit 1380921

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

doc/TODO

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
TODO list for PostgreSQL
22
========================
3-
Last updated: Thu Jan 27 23:46:41 EST 2000
3+
Last updated: Thu Jan 27 23:55:43 EST 2000
44

55
Current maintainer: Bruce Momjian (pgman@candle.pha.pa.us)
66

src/backend/access/nbtree/nbtcompare.c

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtcompare.c,v 1.31 2000/01/26 05:55:58 momjian Exp $
11+
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtcompare.c,v 1.32 2000/01/28 17:23:47 momjian Exp $
1212
*
1313
* NOTES
1414
* These functions are stored in pg_amproc. For each operator class
@@ -35,7 +35,12 @@ btint2cmp(int16 a, int16 b)
3535
int32
3636
btint4cmp(int32 a, int32 b)
3737
{
38-
return a - b;
38+
if (a > b)
39+
return 1;
40+
else if (a == b)
41+
return 0;
42+
else
43+
return -1;
3944
}
4045

4146
int32

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy