From 5e188b9df24ddb3097a79b0ac11a19a25be9e3c7 Mon Sep 17 00:00:00 2001 From: Rob Church Date: Tue, 4 Apr 2006 08:50:05 +0000 Subject: [PATCH] Add basic check for session support in PHP and die if not present --- RELEASE-NOTES | 1 + config/index.php | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index f8622a6e31..473d2386dc 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -158,6 +158,7 @@ Installer: permissions, if said user exists * Changes to some of the wording of explanations for fields * (bug 1734) granting db permissions failed with db usernames containg '-' +* Add basic check for session support in PHP and die if not present Maintenance: * Fix problem reported on mailing list where re-initialising stats didn't work (can't insert diff --git a/config/index.php b/config/index.php index 7051b01ece..39e260ab1d 100644 --- a/config/index.php +++ b/config/index.php @@ -280,6 +280,10 @@ if( $conf->xml ) { If you're running Mandrake, install the php-xml package." ); } +# Crude check for session support +if( !function_exists( 'session_name' ) ) + dieout( "PHP's session module is missing. MediaWiki requires session support in order to function." ); + $memlimit = ini_get( "memory_limit" ); $conf->raiseMemory = false; if( empty( $memlimit ) || $memlimit == -1 ) { -- 2.20.1