[Mediawiki-l] bug in user.php - function matchEditToken ?

ipbwiki list ipbwiki.list at gmail.com
Sat Apr 8 13:27:31 UTC 2006


Hi,

in the function matcheditToken there is a call to a function only available
if you use memcached. The line in question is
$mckey = memsess_key( session_id() );

the memsess_key function is registered in the function "SetupSession" (also
in user.php). This function is only included if $wgSessionsInMemcached is
true tough (as it should).

to solve the problem the function matcheditToken has to be altered.

search for the line:

        if ( $val != $sessionToken ) {

and change this to:

        if ( $val != $sessionToken and $wgSessionsInMemcached ) {


This change will avoid the error "call to undefined function memsess_key"
when the session is lost.

Best regards,
Peter.



More information about the MediaWiki-l mailing list