Changeset 771

Show
Ignore:
Timestamp:
09/18/02 17:03:20
Author:
miyagawa
Message:

0.14

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • PHP-Session/trunk/Changes

    r678 r771  
    11Revision history for Perl extension PHP::Session 
     2 
     30.14  Wed Sep 18 17:02:16 JST 2002 
     4        * Fixed bug that "." is not encoded properly 
     5          (Thanks to Tony Mattila)       
    26 
    370.13  Tue Jul 16 19:35:58 JST 2002 
  • PHP-Session/trunk/lib/PHP/Session.pm

    r678 r771  
    33use strict; 
    44use vars qw($VERSION); 
    5 $VERSION = '0.13'
     5$VERSION = 0.14
    66 
    77use vars qw(%SerialImpl); 
  • PHP-Session/trunk/lib/PHP/Session/Serializer/PHP.pm

    r678 r771  
    1717my $str_re = 's:\d+:"(.*?)";'; 
    1818my $int_re = 'i:(-?\d+);'; 
    19 my $dbl_re = 'd:(-?[\d\.]+);'; 
     19my $dbl_re = 'd:(-?\d+(?:\.\d+)?);'; 
    2020my $arr_re = 'a:(\d+):'; 
    2121my $obj_re = 'O:\d+:"(.*?)":\d+:'; 
     
    111111            return $self->encode_int($value); 
    112112        } 
    113         elsif ($value =~ /^-?[\d\.]+$/) { 
     113        elsif ($value =~ /^-?\d+(?:\.\d+)?$/) { 
    114114            return $self->encode_double($value); 
    115115        } 
  • PHP-Session/trunk/t/07_int_double.t

    r676 r771  
    11use strict; 
    2 use Test::More tests => 7
     2use Test::More tests => 8
    33 
    44use lib 't/lib'; 
     
    1212    $session->set(bar => '-2.1'); 
    1313    $session->set(baz => '2-1'); 
     14    $session->set(dot => '.'); 
    1415    $session->save; 
    1516    ok(-e "t/sess_1234", 'session created'); 
     
    2627    is $session->get('bar'), -2.1; 
    2728    is $session->get('baz'), '2-1'; 
     29    is $session->get('dot'), '.'; 
    2830    $session->destroy; 
    2931}