]> sipb.mit.edu Git - ikiwiki.git/commitdiff
* Avoid locking the wiki at all when handling some basic cgi stuff
authorjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>
Mon, 20 Nov 2006 12:03:35 +0000 (12:03 +0000)
committerjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>
Mon, 20 Nov 2006 12:03:35 +0000 (12:03 +0000)
  (searches, recentchanges).

IkiWiki/CGI.pm
debian/changelog
ikiwiki.pl

index 53237bcdb571c646b5d19d9403d1056cc58dfa8b..14861e398d5e04fa5f050fe3e7626df8f3c3a44d 100644 (file)
@@ -67,8 +67,6 @@ sub decode_form_utf8 ($) { #{{{
 sub cgi_recentchanges ($) { #{{{
        my $q=shift;
        
-       unlockwiki();
-
        # Optimisation: building recentchanges means calculating lots of
        # links. Memoizing htmllink speeds it up a lot (can't be memoized
        # during page builds as the return values may change, but they
@@ -715,6 +713,9 @@ sub cgi (;$$) { #{{{
        elsif ($do eq 'hyperestraier') {
                cgi_hyperestraier();
        }
+
+       # Need to lock the wiki before getting a session.
+       lockwiki();
        
        if (! $session) {
                CGI::Session->name("ikiwiki_session_".encode_utf8($config{wikiname}));
index d381521326be8036c4e6fe9194f0ddc0bc278dfb..b622fa006396ac8c1e6665bdd74afd3966333021 100644 (file)
@@ -12,8 +12,10 @@ ikiwiki (1.34) UNRELEASED; urgency=low
   * Change how post signin actions are propigated through the signin process;
     they're now stored in the session.
   * Add optional "desc" parameter to shortcut definitions.
+  * Avoid locking the wiki at all when handling some basic cgi stuff
+    (searches, recentchanges).
 
- -- Joey Hess <joeyh@debian.org>  Mon, 20 Nov 2006 06:14:51 -0500
+ -- Joey Hess <joeyh@debian.org>  Mon, 20 Nov 2006 06:54:12 -0500
 
 ikiwiki (1.33) unstable; urgency=low
 
index 60ba5e182644b1734d7c3a27939bee5e44a8be64..ff1da353efe881937edd0f5d50a41d1ee6c2c0e5 100755 (executable)
@@ -102,7 +102,6 @@ sub main () { #{{{
        getconfig();
        
        if ($config{cgi}) {
-               lockwiki();
                loadindex();
                require IkiWiki::CGI;
                cgi();