OSDN Git Service

*** empty log message ***
authormorimoto <morimoto@180c8125-5b33-4295-ad04-72a68a15b4cc>
Sat, 2 Aug 2008 15:45:06 +0000 (15:45 +0000)
committermorimoto <morimoto@180c8125-5b33-4295-ad04-72a68a15b4cc>
Sat, 2 Aug 2008 15:45:06 +0000 (15:45 +0000)
lib/Keitairc/SessionManager.pm

index 124e550..8aefb4d 100644 (file)
@@ -1,6 +1,6 @@
 # -*- mode: perl; coding: utf-8 -*-
 # Keitairc::SessionManager
-# $Id: SessionManager.pm,v 1.8 2008-08-02 15:40:27 morimoto Exp $
+# $Id: SessionManager.pm,v 1.9 2008-08-02 15:45:05 morimoto Exp $
 # $Source: /home/ishikawa/work/keitairc/tmp/keitairc/lib/Keitairc/SessionManager.pm,v $
 #
 # Copyright (c) 2008 Jun Morimoto <morimoto@mrmt.net>
@@ -85,6 +85,7 @@ sub search_by_serial_key{
        $user_agent = $me->normalize_user_agent($user_agent);
 
        for my $id (keys(%{$me->{sessions}})){
+               next unless defined $me->{sessions}->{$id}->{serial_key};
                if($me->{sessions}->{$id}->{serial_key} eq $serial_key){
                        if($me->{sessions}->{$id}->{user_agent} eq $user_agent){
                                return $me->{sessions}->{$id};