Skip to content

Commit 76d014a

Browse files
committedDec 10, 2012
firstly, I'm tired of the 0.0.0.0.0.0 crap, so juno's versionining system has been changed for the first time in three years. versions are now whatever I want them to be, and this one shall be called version 5.8.
1 parent 0e02c27 commit 76d014a

File tree

5 files changed

+17
-17
lines changed

5 files changed

+17
-17
lines changed
 

‎inc/channel/mine.pm

+5-2
Original file line numberDiff line numberDiff line change
@@ -119,11 +119,14 @@ sub take_lower_time {
119119
delete $channel->{topic};
120120

121121
# unset all channel modes
122-
my $modestring = ($channel->mode_string_all(gv('SERVER')))[0];
122+
my ($modestring, $servermodestring) = $channel->mode_string_all(gv('SERVER'));
123123
$modestring =~ s/\+/\-/;
124124
send_all($channel, ':'.gv('SERVER', 'name')." MODE $$channel{name} $modestring");
125-
$channel->{modes} = {};
126125

126+
# hackery: use the server mode string to reset all modes.
127+
# ($channel, $server, $source, $modestr, $force, $over_protocol)
128+
$channel->handle_mode_string(gv('SERVER'), gv('SERVER'), $servermodestring, 1, 1);
129+
127130
notice_all($channel, 'channel properties reset');
128131
return $channel->{time}
129132
}

‎inc/connection.pm

+1-1
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,7 @@ sub done {
292292

293293
if ($connection->{type}) {
294294
# share this quit with the children
295-
server::mine::fire_command_all(quit => $connection, $reason) unless $connection->{type}->isa('server');
295+
server::mine::fire_command_all(quit => $connection, $reason);
296296

297297
# tell user.pm or server.pm that the connection is closed
298298
$connection->{type}->quit($reason)

‎inc/ircd.pm

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ use utils qw(conf lconf log2 fatal gv set);
1010
utils::ircd_LOAD();
1111

1212
our @reloadable;
13-
my ($VERSION, %global) = '5.0.0.6';
13+
my ($VERSION, %global) = '5.8';
1414

1515
sub start {
1616

‎mod/core_scommands.pm

+7-12
Original file line numberDiff line numberDiff line change
@@ -318,27 +318,21 @@ sub sjoin {
318318
my ($server, $data, $user, $chname, $time) = @_;
319319
my $channel = channel::lookup_by_name($chname);
320320

321-
# the channel exists, so just join
322-
if ($channel) {
323-
return if $channel->has_user($user);
324-
325-
# take the lower time
326-
$channel->channel::mine::take_lower_time($time);
327-
328-
}
329-
330321
# channel doesn't exist; make a new one
331-
else {
322+
if (!$channel) {
332323
$channel = channel->new({
333324
name => $chname,
334325
time => $time
335326
});
336327
}
337328

338-
$channel->cjoin($user, $time);
329+
# take lower time if necessary, and add the user to the channel.
330+
$channel->channel::mine::take_lower_time($time);
331+
$channel->cjoin($user, $time) unless $channel->has_user($user);
339332

340-
# for each user in the channel
333+
# for each user in the channel, send a JOIN message.
341334
$channel->channel::mine::send_all(q(:).$user->full." JOIN $$channel{name}");
335+
342336
}
343337

344338
# add user flags
@@ -547,6 +541,7 @@ sub skill {
547541

548542
# we ignore any non-local users
549543
$tuser->{conn}->done("Killed: $reason [$$user{nick}]") if $tuser->is_local;
544+
550545
}
551546

552547
$mod

‎mod/core_ucommands.pm

+3-1
Original file line numberDiff line numberDiff line change
@@ -476,12 +476,14 @@ sub cjoin {
476476
($ur, $sr) = $channel->handle_mode_string($me, $me, $str, 1, 1);
477477
}
478478

479+
480+
479481
# tell servers that the user joined and the automatic modes were set
480482
server::mine::fire_command_all(sjoin => $user, $channel, $time);
481483
server::mine::fire_command_all(cmode => $me, $channel, $time, $me->{sid}, $sr) if $sr;
482484

483485
$channel->channel::mine::cjoin($user, $time, 1)
484-
}
486+
485487
}
486488

487489
sub names {

0 commit comments

Comments
 (0)