Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit443a44b

Browse files
committed
Avoid integer overflow when LIMIT + OFFSET >= 2^63.
This fixes bug #6139 reported by Hitoshi Harada.
1 parent8daf82e commit443a44b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎src/backend/executor/nodeLimit.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ ExecLimit(LimitState *node)
120120
* the state machine state to record having done so.
121121
*/
122122
if (!node->noCount&&
123-
node->position>=node->offset+node->count)
123+
node->position-node->offset>=node->count)
124124
{
125125
node->lstate=LIMIT_WINDOWEND;
126126
returnNULL;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp