X-Git-Url: https://git.p6c8.net/selfforum.git/blobdiff_plain/9b9648223ab2db3960298d04b83ecdd147ec21e9..f3e4ec2c7444625d5881d373ef0cfa9b405b771b:/selfforum-cgi/shared/Id.pm diff --git a/selfforum-cgi/shared/Id.pm b/selfforum-cgi/shared/Id.pm index 480a57e..4d09143 100644 --- a/selfforum-cgi/shared/Id.pm +++ b/selfforum-cgi/shared/Id.pm @@ -4,7 +4,7 @@ package Id; # # # File: shared/Id.pm # # # -# Authors: André Malo , 2001-05-03 # +# Authors: André Malo # # # # Description: compose an unique ID (in CGI context) # # # @@ -16,6 +16,16 @@ use vars qw( @EXPORT ); +################################################################################ +# +# Version check +# +# last modified: +# $Date$ (GMT) +# by $Author$ +# +sub VERSION {(q$Revision$ =~ /([\d.]+)\s*$/)[0] or '0.0'} + ################################################################################ # # Export @@ -59,6 +69,8 @@ sub unique_id () { # sub to_base64 ($) { my $x = shift; + return '' unless defined $x; + my $y = $table[$x % 64]; $y = $table[$x % 64].$y while ($x = int ($x/64)); @@ -79,7 +91,7 @@ BEGIN { ); } -# keep require happy +# keep 'require' happy 1; #