On Sun, Jun 12, 2016 at 08:01:03AM +0200, Jeremie Courreges-Anglas wrote:

> Marcus Glocker <[email protected]> writes:
> 
> > On Sun, Jun 12, 2016 at 06:54:28AM +0200, Jeremie Courreges-Anglas wrote:
> >
> >> Marcus Glocker <[email protected]> writes:
> >> 
> >> > On Sun, Jun 05, 2016 at 08:04:26AM +0200, Marcus Glocker wrote:
> >> >
> >> >> ICB has been designed for a user always need to be joined to a group.
> >> >> With the irssi-icb module you can break this rule currently by running
> >> >> the '/window close' command and therefore crash irssi simply:
> >> >> 
> >> >>         /window close
> >> >>         /j 2
> >> >>         Segmentation fault (core dumped)
> >> >> 
> >> >> icb-channels.c:icb_change_channel() will try to compare the current
> >> >> group with the new group on the next join command, and in case of a
> >> >> previous '/window close' irssi has already destroyed our group and
> >> >> freed the reference to it.  Hence icb_change_channel() is comparing
> >> >> a group string against a freed memory address and segfaults.
> >> >> 
> >> >> Attached patch disables the '/window close' command for ICB
> >> >> connections, since this just shouldn't be supported.
> >> >
> >> > This is an improved version of the last diff.  It still allows one to
> >> > close windows for private queries but just returns an error when you
> >> > try to close your ICB group window.
> >> 
> >> I would prefer if /wc would just disconnect from the server, there
> >> is no point in keeping the connection around since as you say a user is
> >
> > Well, I find /wc still useful to close old private queries on icb, which
> > will work now with the updated diff.
> 
> Oh I thought that private query windows were not affected by the crash,
> now this patch looks even better.

They where not.  But my first diff did disable /wc for *all* ICB
windows, so it fixed the crash but you couldn't close any windows
anymore!  With the new diff you can now close private queries, but
not your ICB group anymore.

Reply via email to