in reply to Comparing timestamps

I would concur with the suggestion made by caedes above.

A far better solution I think would be to make use of the Cache::Cache function for the storage of session information - This caching package includes a facility to expire entries and to automatically purge expired entries at set intervals or upon cache access (set or retrieval).

For example, your cache interface could look as simple as the following:

use Cache::FileCache; my $cache = Cache::FileCache->new ( 'auto_purge_on_get' => 1, 'default_expires_in' => '2 hours' ); . . $cache->get( $key ); if ( !defined $cache->get( $key ) ) { # Create new session } $cache->set( $key, $value );

 

perl -le 'print+unpack("N",pack("B32","00000000000000000000001000110101"))'