[bknr-cvs] edi changed trunk/thirdparty/hunchentoot/

BKNR Commits bknr at bknr.net
Mon Dec 28 16:40:27 UTC 2009


Revision: 4494
Author: edi
URL: http://bknr.net/trac/changeset/4494

Fix reset-sessions

U   trunk/thirdparty/hunchentoot/doc/index.xml
U   trunk/thirdparty/hunchentoot/session.lisp

Modified: trunk/thirdparty/hunchentoot/doc/index.xml
===================================================================
--- trunk/thirdparty/hunchentoot/doc/index.xml	2009-12-27 23:14:59 UTC (rev 4493)
+++ trunk/thirdparty/hunchentoot/doc/index.xml	2009-12-28 16:40:26 UTC (rev 4494)
@@ -2134,10 +2134,15 @@
 
   <clix:function name='reset-sessions'>
   <clix:lambda-list>
+  <clix:lkw>optional
+  </clix:lkw> acceptor
   </clix:lambda-list>
   <clix:returns>|
   </clix:returns>
-    <clix:description>Removes <em>all</em> stored sessions.
+    <clix:description>Removes <em>all</em> stored sessions
+    of <clix:arg>acceptor</clix:arg>.  The default
+    for <clix:arg>acceptor</clix:arg>
+    is <clix:ref>*ACCEPTOR*</clix:ref>.
     </clix:description>
   </clix:function>
 

Modified: trunk/thirdparty/hunchentoot/session.lisp
===================================================================
--- trunk/thirdparty/hunchentoot/session.lisp	2009-12-27 23:14:59 UTC (rev 4493)
+++ trunk/thirdparty/hunchentoot/session.lisp	2009-12-28 16:40:26 UTC (rev 4494)
@@ -353,10 +353,10 @@
 cease to be valid."
   (setq *session-secret* (create-random-string 10 36)))
 
-(defun reset-sessions ()
-  "Removes ALL stored sessions."
-  (with-session-lock-held ((session-db-lock *acceptor*))
-    (loop for (nil . session) in (session-db *acceptor*)
+(defun reset-sessions (&optional (acceptor *acceptor*))
+  "Removes ALL stored sessions of ACCEPTOR."
+  (with-session-lock-held ((session-db-lock acceptor))
+    (loop for (nil . session) in (session-db acceptor)
           do (funcall *session-removal-hook* session))
     (setq *session-db* nil))
   (values))
\ No newline at end of file





More information about the Bknr-cvs mailing list