From 796b81b84d9d751615be6d4472209a58096b4e58 Mon Sep 17 00:00:00 2001 From: Brion Vibber Date: Mon, 17 Apr 2006 09:00:55 +0000 Subject: [PATCH] Revert the rest of r13645; totally broken, tries to call an installer-specific function before it's included, and why's it in an include file anyway? --- RELEASE-NOTES | 2 -- config/index.php | 3 +-- install-utils.inc | 50 ++++------------------------------------------- 3 files changed, 5 insertions(+), 50 deletions(-) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index 540d8e2f51..00e9e8b961 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -68,8 +68,6 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN anchor identifiers * (bug 5519) Allow sidebar cache to be disabled; disable it by default. * Maintenance script to import the contents of a text file into a wiki page -* installer: hide errors returned when trying to dl() mysql.so / pgsql.so -* installer: cleanly outputbuffer when dieing out * Add $wgReservedUsernames configuration directive to block account creation/use * (bug 5576) Remove debugging hack in session check * (bug 5426) Lowercase treatment of titles in rights log leads to broken links on Special:Log diff --git a/config/index.php b/config/index.php index fd4959c52c..8bb6247099 100644 --- a/config/index.php +++ b/config/index.php @@ -1309,8 +1309,7 @@ if ( \$wgCommandLineMode ) { } function dieout( $text ) { - outputFooter( $text ); - die(); + die( $text . "\n\n\n" ); } function importVar( &$var, $name, $default = "" ) { diff --git a/install-utils.inc b/install-utils.inc index 1f5679dd1e..9a8bab1272 100644 --- a/install-utils.inc +++ b/install-utils.inc @@ -17,20 +17,15 @@ function install_version_checks() { $gotdatabase = 0; ## XXX We should quiet the warnings thrown here - if (extension_loaded('mysql') or @dl('mysql.so')) { + if (extension_loaded('mysql') or dl('mysql.so')) { $gotdatabase = 'mysql'; } - else if (extension_loaded('pgsql') or @dl('pgsql.so')) { + else if (extension_loaded('pgsql') or dl('pgsql.so')) { $gotdatabase = 'pg'; } if (!$gotdatabase) { - global $wgCommandLineMode; - - $error ="Could not load the MySQL or the PostgreSQL driver! Please compile ". - "php with either --with-mysql or --with-pgsql, or install the mysql.so or pg.so module.
\n". - " If the database extension is installed (eg php-mysql), make sure it is enabled in your php.ini.\n"; - if( $wgCommandLineMode ) { print $error; } - else { outputFooter($error); } + print "Could not load the MySQL or the PostgreSQL driver! Please compile ". + "php with either --with-mysql or --with-pgsql, or install the mysql.so or pg.so module.\n"; exit; } @@ -162,41 +157,4 @@ function field_info( $table, $field ) { return false; } -/** - * Used to end the HTML stream when we die out - */ -function outputFooter( $text ) { -print $text; -print << - - -
- - -
- -

MediaWiki is Copyright © 2001-2006 by Magnus Manske, Brion Vibber, Lee Daniel Crocker, Tim Starling, Erik Möller, Gabriel Wicke and others.

-
-
- - - - - - -END; - -} ?> -- 2.20.1