Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix Int value range is incorrect #862

Closed
wants to merge 1 commit into from

Conversation

moneytoyang
Copy link
Contributor

fix int value range is incorrect #826

@nebula-community-bot
Copy link
Member

Can one of the admins verify this patch?

Copy link
Contributor

@laura-ding laura-ding left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you very much for your contribution

| KW_UPTO INTEGER KW_STEPS { $$ = new StepClause($2, true); }
| INTEGER KW_STEPS {
if ((uint64_t)$1 == 9223372036854775808ULL) {
LOG(ERROR) << "Integer overflow";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to handle exceptions

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where is the exception?

@@ -285,8 +285,11 @@ IP_OCTET ([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])
yyterminate();
}
}
int64_t val = 0;
uint64_t val = 0;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hex and octal do not need to be processed

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why? Don't they overflow?

@laura-ding
Copy link
Contributor

I have fixed this problem on p #1181, so close this

@laura-ding laura-ding closed this Nov 1, 2019
yixinglu pushed a commit to yixinglu/nebula that referenced this pull request Jan 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants