-
Notifications
You must be signed in to change notification settings - Fork 5.8k
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
privilege/privileges: sort user records in privilege cache #7211
Changes from 1 commit
8a9f4a1
4883b7b
5c7a96e
a85f386
851f8c8
d9aa8f4
c2991c1
e1137c1
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -194,6 +194,7 @@ func (s sortedUserRecord) Less(i, j int) bool { | |
} | ||
|
||
// compareHost compares two host string using some special rules, return value 1, 0, -1 means > = <. | ||
// TODO: Check how MySQL do it exactly, instead of guess its rules. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It may be overkill, if some user really meet the complex cases and complain, I'll consider. |
||
func compareHost(x, y string) int { | ||
// The more-specific, the smaller it is. | ||
// The pattern '%' means “any host” and is least specific. | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
create an issue for this TODO, and add the link here