fix(ipfilter): skip an empty ipfilter.dat and clarify the paranoid tooltip - #581
Merged
Merged
Conversation
…oltip Two IP-filter UX fixes from issue amule-project#580: - LoadFromFile treated a 0-byte ipfilter.dat as a load failure ("unknown format encountered"), because the archive/format detector does not recognise an empty file. An empty file is a valid "no ranges" list (a user who cleared it, or an auto-update that has not populated it yet), so return 0 quietly instead. - Reword the "Paranoid handling of non-matching IPs" tooltip. The old "Use with caution" gave no hint whether caution applied to enabling or disabling; the new text says what the check does (anti-spoofing) and that disabling it is the risk. Catalogs regenerated via update-po.sh.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two small IP-filter UX fixes from #580 (@ghysler):
Empty
ipfilter.dat—LoadFromFilereported "unknown format encountered" for a 0-byte file, because the format/archive detector doesn't recognise an empty file as a valid (empty) list. An empty file is a legitimate "no ranges" state (a user who cleared it, or an auto-update that hasn't populated it yet), so it now returns 0 ranges quietly.Paranoid-filter tooltip — the "Paranoid handling of non-matching IPs" checkbox ships enabled, and its tooltip ended with a bare "Use with caution" that didn't say whether the caution applied to enabling or disabling. Reworded to state what the check does and that disabling it is the risk:
Catalogs regenerated with
scripts/update-po.sh(the reworded string is a new msgid).amuledbuilds clean; clang-format and Tier-2 clang-tidy clean on the diff.