Skip to content

Commit 440a330

Browse files
committed
Fix a small 64-bit problem in tsearch patch.
1 parent 46dedde commit 440a330

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/backend/utils/adt/tsvector.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $PostgreSQL: pgsql/src/backend/utils/adt/tsvector.c,v 1.1 2007/08/21 01:11:19 tgl Exp $
10+
* $PostgreSQL: pgsql/src/backend/utils/adt/tsvector.c,v 1.2 2007/08/21 01:45:33 tgl Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -434,8 +434,9 @@ tsvectorin(PG_FUNCTION_ARGS)
434434
if (state.curpos - state.word >= MAXSTRLEN)
435435
ereport(ERROR,
436436
(errcode(ERRCODE_SYNTAX_ERROR),
437-
errmsg("word is too long (%d bytes, max %d bytes)",
438-
state.curpos - state.word, MAXSTRLEN)));
437+
errmsg("word is too long (%ld bytes, max %ld bytes)",
438+
(long) (state.curpos - state.word),
439+
(long) MAXSTRLEN)));
439440

440441
arr[len].entry.len = state.curpos - state.word;
441442
if (cur - tmpbuf > MAXSTRPOS)

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