Changeset 53d6269


Ignore:
Timestamp:
Dec 1, 2015, 6:50:07 PM (8 years ago)
Author:
Karl Ramm <xyzzy-github@1ts.org>
Branches:
master, release-1.10
Children:
02514d9, 3d20ce1
Parents:
ff58239 (diff), 8fcd3e7 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:
Merge pull request #165 from JasonGross/smartnarrow-view

Add some see-alsos to smartnarrow and smartfilter
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • commands.c

    rca1fb26a r8fcd3e7  
    548548              "optional color arguments are used they specifies the colors that\n"
    549549              "messages matching this filter should be displayed in.\n\n"
    550               "SEE ALSO: view, viewclass, viewuser\n"),
     550              "SEE ALSO: smartfilter, smartnarrow, view, viewclass, viewuser\n"),
    551551
    552552  OWLCMD_ARGS("colorview", owl_command_colorview, OWL_CTX_INTERACTIVE,
     
    585585              "filter expression that will be dynamically created by BarnOwl and then\n"
    586586              "applied as the view's filter\n"
    587               "SEE ALSO: filter, viewclass, viewuser\n"),
     587              "SEE ALSO: filter, smartfilter, smartnarrow, viewclass, viewuser\n"),
    588588
    589589  OWLCMD_ARGS("smartnarrow", owl_command_smartnarrow, OWL_CTX_INTERACTIVE,
     
    599599              "    then narrow to the class and instance.\n"
    600600              "If '-r' or '--related' is specified, behave as though the\n"
    601               "    'narrow-related' variable was inverted."),
     601              "    'narrow-related' variable was inverted.\n\n"
     602              "SEE ALSO: filter, smartfilter, view, viewclass, viewuser\n"),
    602603
    603604  OWLCMD_ARGS("smartfilter", owl_command_smartfilter, OWL_CTX_INTERACTIVE,
     
    610611              "If the curmsg is a class message, the filter is that class.\n"
    611612              "If the curmsg is a class message and '-i' is specified\n"
    612               "    the filter is to that class and instance.\n"),
     613              "    the filter is to that class and instance.\n\n"
     614              "SEE ALSO: filter, smartnarrow, view, viewclass, viewuser\n"),
    613615
    614616  OWLCMD_ARGS("viewclass", owl_command_viewclass, OWL_CTX_INTERACTIVE,
     
    618620              "matching the specified class and switch the current view\n"
    619621              "to it.\n\n"
    620               "SEE ALSO: filter, view, viewuser\n"),
     622              "SEE ALSO: filter, smartfilter, smartnarrow, view, viewuser\n"),
    621623  OWLCMD_ALIAS("vc", "viewclass"),
    622624
     
    627629              "matching the specified user and switch the current\n"
    628630              "view to it.\n\n"
    629               "SEE ALSO: filter, view, viewclass\n"),
     631              "SEE ALSO: filter, smartfilter, smartnarrow, view, viewclass\n"),
    630632  OWLCMD_ALIAS("vu", "viewuser"),
    631633  OWLCMD_ALIAS("viewperson", "viewuser"),
  • perl/modules/IRC/lib/BarnOwl/Module/IRC.pm

    r926c721 rd4f33f1  
    562562                               "[" . $conn->alias . "] Reconnect cancelled");
    563563        $conn->cancel_reconnect;
     564        delete $ircnets{$conn->alias};
     565    } elsif (exists $ircnets{$conn->alias}) { # inconsistent state; no socket, but not yet deleted
     566        BarnOwl::admin_message('IRC',
     567                               "[" . $conn->alias . "] Attempt to disconnect from a socketless connection; deleting it");
    564568        delete $ircnets{$conn->alias};
    565569    }
  • perl/modules/IRC/lib/BarnOwl/Module/IRC/Connection.pm

    rbe43554 r4379288  
    437437}
    438438
     439sub rejoin_channels {
     440    my $self = shift;
     441    my @channels = @_;
     442    # As reported in https://barnowl.mit.edu/ticket/274, if we reconnect to
     443    # too many at once, the server rejects us.  Empirically, this is about
     444    # 20-26, so we set the cap at 15, then delay further joins for 5 seconds.
     445    my $MAX_RECONNECT_CHANNELS = 15;
     446    my $DELAY = 5;
     447    foreach my $c (@channels[ 0 .. $MAX_RECONNECT_CHANNELS ]) {
     448        $self->conn->send_msg(join => $c);
     449    }
     450    if ($MAX_RECONNECT_CHANNELS < $#channels) {
     451        my $remaining = $#channels - $MAX_RECONNECT_CHANNELS;
     452        my $cur_alias = $self->alias;
     453        BarnOwl::admin_message('IRC', "[$cur_alias] Delaying $remaining autorejoins for $DELAY seconds");
     454        # if we don't assign the timer to anything, then it gets garbage
     455        # collected, and never runs
     456        $self->{autoconnect_channels_delay_timer} = BarnOwl::Timer->new({
     457            name  => "IRC rejoin overflow timer ($remaining remaining)",
     458            after => $DELAY,
     459            cb    => sub {
     460                rejoin_channels($self, @channels[ $MAX_RECONNECT_CHANNELS .. $#channels ]);
     461            }
     462        });
     463    }
     464}
     465
     466
    439467sub connected {
    440468    my $self = shift;
     
    443471    $self->cancel_reconnect;
    444472    if ($self->autoconnect_channels) {
    445         for my $c (@{$self->autoconnect_channels}) {
    446             $self->conn->send_msg(join => $c);
    447         }
     473        rejoin_channels($self, @{$self->autoconnect_channels});
    448474    }
    449475    $self->conn->enable_ping(60, sub {
  • zephyr.c

    r18380fd rff58239  
    13111311{
    13121312  int n = strcspn(in, "./");
    1313   char *realm = strchrnul(in, '@');
     1313  const char *realm = strchr(in, '@');
     1314  if (realm == NULL)
     1315    realm = in + strlen(in);
    13141316
    13151317  if (in + n >= realm ||
Note: See TracChangeset for help on using the changeset viewer.