diff --git a/lib/ezutils/classes/ezsession.php b/lib/ezutils/classes/ezsession.php
index <HASH>..<HASH> 100644
--- a/lib/ezutils/classes/ezsession.php
+++ b/lib/ezutils/classes/ezsession.php
@@ -56,12 +56,18 @@ function &eZSessionRead( $key )
 
     $key =& $db->escapeString( $key );
 
-    $sessionRes =& $db->arrayQuery( "SELECT data, user_id FROM ezsession WHERE session_key='$key'" );
+    $sessionRes =& $db->arrayQuery( "SELECT data, user_id, expiration_time FROM ezsession WHERE session_key='$key'" );
 
     if ( count( $sessionRes ) == 1 )
     {
+        $ini =& eZINI::instance();
+
+        $sessionUpdatesTime = $sessionRes[0]['expiration_time'] - $ini->variable( 'Session', 'SessionTimeout' );
+        $sessionIdle = time() - $sessionUpdatesTime;
+
         $data =& $sessionRes[0]['data'];
         $GLOBALS['eZSessionUserID'] = $sessionRes[0]['user_id'];
+        $GLOBALS['eZSessionIdleTime'] = $sessionIdle;
 
         return $data;
     }
- Fixed missing patch to ezsession for handling user idle time. Needed to make new content search work properly.


git-svn-id: file:///home/patrick.allaert/svn-git/ezp-repo/ezpublish/trunk@<I> a<I>eee8c-daba-<I>-acae-fa<I>f<I>