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

ignore overwrites #78

Closed
eked opened this Issue Jul 2, 2014 · 3 comments

Comments

Projects
None yet
4 participants
@eked

eked commented Jul 2, 2014

I don't know if I'm missing something here (new user), but after ignoring, say, messages that contain 'lol' only like this: /ignore -regexp -pattern "^[lL][oO][lL]$" * PUBLIC, when trying to /ignore * JOINS PARTS QUITS, the two entries get merged without the regexp pattern and I end up ignoring all public messages. If I add the ignore rules in opposite order or edit config manually it seems to work fine.

@dgl

This comment has been minimized.

Member

dgl commented Jul 3, 2014

You're not missing something, the fact this is inconsistent is a bug.

The problem here is ignore_find() is not flexible enough, so the code in fe-common/core/fe-ignore.c can't specify that it doesn't want ignores with patterns, yet it does ignore them when adding with a pattern:

rec = patternarg != NULL ? NULL: ignore_find(servertag, mask, channels);

I actually already made some changes to ignore_find in pull #80, I wonder if it would be worth cleaning up that API a little more so that it's possible to specify not wanting ignores with patterns attached, which /ignore could then use.

@ailin-nemui ailin-nemui added the bug label Sep 18, 2015

@ailin-nemui ailin-nemui modified the milestone: 0.8.20 Nov 1, 2015

LemonBoy added a commit to LemonBoy/irssi that referenced this issue Jan 3, 2016

Clean up the ignore_find API to make it more powerful.
This way we prevent the creation of duplicate ignores since the old code
skipped the ignore_find call when a pattern was specified.
It should also cover all the cases where the ignores would be wrongly
overwritten, such as the case outlined in irssi#78.
@ailin-nemui

This comment has been minimized.

Contributor

ailin-nemui commented Jan 6, 2016

@swiniopas would you be interested in testing that patch?

@ailin-nemui

This comment has been minimized.

Contributor

ailin-nemui commented Jan 11, 2016

please reopen if this is still an issue in 0.8.18-beta2 or later

@dequis dequis removed this from the 0.8.21 milestone Mar 22, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment