diff options
author | Pascal Terjan <pterjan@gmail.com> | 2016-12-06 14:31:53 +0000 |
---|---|---|
committer | Pascal Terjan <pterjan@gmail.com> | 2016-12-06 14:31:53 +0000 |
commit | 4bbd1931281df6c15b67bbe37883a482fc632fa3 (patch) | |
tree | 9977a100101fd4df364cbd4c1ecc600518f3b647 /lib | |
parent | 9aa0a5137730d580da32a7ad53f5f12a0057b6dc (diff) | |
download | identity-4bbd1931281df6c15b67bbe37883a482fc632fa3.tar identity-4bbd1931281df6c15b67bbe37883a482fc632fa3.tar.gz identity-4bbd1931281df6c15b67bbe37883a482fc632fa3.tar.bz2 identity-4bbd1931281df6c15b67bbe37883a482fc632fa3.tar.xz identity-4bbd1931281df6c15b67bbe37883a482fc632fa3.zip |
Fix previous commit
Diffstat (limited to 'lib')
-rw-r--r-- | lib/CatDap/Controller/user.pm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/CatDap/Controller/user.pm b/lib/CatDap/Controller/user.pm index 8c14cfd..6f8ac9f 100644 --- a/lib/CatDap/Controller/user.pm +++ b/lib/CatDap/Controller/user.pm @@ -118,7 +118,8 @@ sub get_keyprefix : Private { if ($c->req->address =~ m/:/) { # For IPv6 the first 3 can be special and shared by many people, # bytes 6-8 are more interesting - $keyprefix = sprintf( "%02x%02x%02x", splice(5, 3, split /:/, $c->req->address)); + my @address_chunks = split /:/, $c->req->address; + $keyprefix = sprintf( "%02x%02x%02x", splice(@address_chunks, 5, 3)); } else { $keyprefix = sprintf( "%02x%02x%02x", split /\./, $c->req->address ); |