SOURCES (DEVEL): drupal-cron.patch, drupal-sitesdir.patch, drupal-...

bszx bszx at pld-linux.org
Sun Feb 17 22:09:58 CET 2008


Author: bszx                         Date: Sun Feb 17 21:09:58 2008 GMT
Module: SOURCES                       Tag: DEVEL
---- Log message:
- updated for 5.7

---- Files affected:
SOURCES:
   drupal-cron.patch (1.5.2.2 -> 1.5.2.3) , drupal-sitesdir.patch (1.2.2.1 -> 1.2.2.2) , drupal-themedir2.patch (1.1.2.1 -> 1.1.2.2) , drupal-topdir.patch (1.2.2.2.2.1 -> 1.2.2.2.2.2) 

---- Diffs:

================================================================
Index: SOURCES/drupal-cron.patch
diff -u SOURCES/drupal-cron.patch:1.5.2.2 SOURCES/drupal-cron.patch:1.5.2.3
--- SOURCES/drupal-cron.patch:1.5.2.2	Mon Mar 12 11:20:17 2007
+++ SOURCES/drupal-cron.patch	Sun Feb 17 22:09:52 2008
@@ -1,33 +1,56 @@
---- drupal/includes/bootstrap.inc	2007-03-12 11:29:22.377223778 +0200
-+++ drupal/includes/bootstrap.inc	2007-03-12 12:19:17.196516132 +0200
+diff -uNdr drupal-5.7.old/cron.php drupal-5.7/cron.php
+--- drupal-5.7.old/cron.php	2006-08-09 09:42:55.000000000 +0200
++++ drupal-5.7/cron.php	2008-02-16 15:50:48.000000000 +0100
+@@ -1,3 +1,4 @@
++#!/usr/bin/php
+ <?php
+ // $Id$
+ 
+@@ -6,6 +7,13 @@
+  * Handles incoming requests to fire off regularly-scheduled tasks (cron jobs).
+  */
+ 
++// If not in 'safe mode', increase the memory limit
++if (!ini_get('safe_mode')) {
++  ini_set('memory_limit', '20M');
++}
++
++chdir(dirname(__FILE__));
++
+ include_once './includes/bootstrap.inc';
+ drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);
+ drupal_cron_run();
+diff -uNdr drupal-5.7.old/includes/bootstrap.inc drupal-5.7/includes/bootstrap.inc
+--- drupal-5.7.old/includes/bootstrap.inc	2008-01-10 23:14:24.000000000 +0100
++++ drupal-5.7/includes/bootstrap.inc	2008-02-16 16:02:23.000000000 +0100
 @@ -201,7 +201,7 @@
  
-   $confdir = '/etc/webapps/drupal/sites';
-   $uri = explode('/', $_SERVER['PHP_SELF'] ? $_SERVER['PHP_SELF'] : $_SERVER['SCRIPT_FILENAME']);
+   $confdir = 'sites';
+   $uri = explode('/', $_SERVER['SCRIPT_NAME'] ? $_SERVER['SCRIPT_NAME'] : $_SERVER['SCRIPT_FILENAME']);
 -  $server = explode('.', implode('.', array_reverse(explode(':', rtrim($_SERVER['HTTP_HOST'], '.')))));
 +  $server = explode('.', implode('.', array_reverse(explode(':', rtrim(@$_SERVER['HTTP_HOST'], '.')))));
    for ($i = count($uri) - 1; $i > 0; $i--) {
      for ($j = count($server); $j > 0; $j--) {
        $dir = implode('.', array_slice($server, -$j)) . implode('.', array_slice($uri, 0, $i));
-@@ -235,7 +235,7 @@
- function conf_init() {
-   global $db_url, $db_prefix, $base_url, $base_path, $base_root, $conf, $installed_profile;
+@@ -240,7 +240,7 @@
+   global $db_url, $db_prefix, $cookie_domain, $conf, $installed_profile;
    $conf = array();
+ 
 -  include_once './'. conf_path() .'/settings.php';
 +  include_once conf_path() .'/settings.php';
  
    if (isset($base_url)) {
      // Parse fixed base URL from settings.php.
-@@ -250,7 +250,7 @@
-   else {
-     // Create base URL
-     $base_root = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] == 'on') ? 'https' : 'http';
--    $base_url = $base_root .= '://'. $_SERVER['HTTP_HOST'];
-+    $base_url = $base_root .= '://'. @$_SERVER['HTTP_HOST'];
-     if ($dir = trim(dirname($_SERVER['PHP_SELF']), '\,/')) {
-       $base_path = "/$dir";
-       $base_url .= $base_path;
-@@ -798,7 +798,7 @@
+@@ -258,7 +258,7 @@
+ 
+     // As $_SERVER['HTTP_HOST'] is user input, ensure it only contains
+     // characters allowed in hostnames.
+-    $base_url = $base_root .= '://'. preg_replace('/[^a-z0-9-:._]/i', '', $_SERVER['HTTP_HOST']);
++    $base_url = $base_root .= '://'. preg_replace('/[^a-z0-9-:._]/i', '', @$_SERVER['HTTP_HOST']);
+ 
+     // $_SERVER['SCRIPT_NAME'] can, in contrast to $_SERVER['PHP_SELF'], not
+     // be modified by a visitor.
+@@ -886,7 +886,7 @@
  
      case DRUPAL_BOOTSTRAP_ACCESS:
        // Deny access to hosts which were banned - t() is not yet available.
@@ -36,24 +59,3 @@
          header('HTTP/1.1 403 Forbidden');
          print 'Sorry, '. $_SERVER['REMOTE_ADDR']. ' has been banned.';
          exit();
---- drupal-4.6.11/cron.php	2007-01-30 18:02:41.911795649 +0200
-+++ drupal-5.1/cron.php	2007-03-12 11:35:43.444806437 +0200
-@@ -1,3 +1,4 @@
-+#!/usr/bin/php
- <?php
- // $Id$
- 
-@@ -6,6 +7,13 @@
-  * Handles incoming requests to fire off regularly-scheduled tasks (cron jobs).
-  */
- 
-+// If not in 'safe mode', increase the memory limit
-+if (!ini_get('safe_mode')) {
-+  ini_set('memory_limit', '20M');
-+}
-+
-+chdir(dirname(__FILE__));
-+
- include_once './includes/bootstrap.inc';
- drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);
- drupal_cron_run();

================================================================
Index: SOURCES/drupal-sitesdir.patch
diff -u SOURCES/drupal-sitesdir.patch:1.2.2.1 SOURCES/drupal-sitesdir.patch:1.2.2.2
--- SOURCES/drupal-sitesdir.patch:1.2.2.1	Fri Jan 26 15:10:10 2007
+++ SOURCES/drupal-sitesdir.patch	Sun Feb 17 22:09:53 2008
@@ -1,11 +1,12 @@
---- drupal-5.0/includes/bootstrap.inc~	2007-01-26 13:05:53.697188263 +0200
-+++ drupal-5.0/includes/bootstrap.inc	2007-01-26 13:06:43.528313680 +0200
+diff -uNdr drupal-5.7.old1/includes/bootstrap.inc drupal-5.7/includes/bootstrap.inc
+--- drupal-5.7.old1/includes/bootstrap.inc	2008-02-16 16:02:23.000000000 +0100
++++ drupal-5.7/includes/bootstrap.inc	2008-02-16 16:06:30.000000000 +0100
 @@ -199,7 +199,7 @@
      return $conf;
    }
  
 -  $confdir = 'sites';
 +  $confdir = '/etc/webapps/drupal/sites';
-   $uri = explode('/', $_SERVER['PHP_SELF'] ? $_SERVER['PHP_SELF'] : $_SERVER['SCRIPT_FILENAME']);
-   $server = explode('.', implode('.', array_reverse(explode(':', rtrim($_SERVER['HTTP_HOST'], '.')))));
+   $uri = explode('/', $_SERVER['SCRIPT_NAME'] ? $_SERVER['SCRIPT_NAME'] : $_SERVER['SCRIPT_FILENAME']);
+   $server = explode('.', implode('.', array_reverse(explode(':', rtrim(@$_SERVER['HTTP_HOST'], '.')))));
    for ($i = count($uri) - 1; $i > 0; $i--) {

================================================================
Index: SOURCES/drupal-themedir2.patch
diff -u SOURCES/drupal-themedir2.patch:1.1.2.1 SOURCES/drupal-themedir2.patch:1.1.2.2
--- SOURCES/drupal-themedir2.patch:1.1.2.1	Fri Jan 26 15:10:11 2007
+++ SOURCES/drupal-themedir2.patch	Sun Feb 17 22:09:53 2008
@@ -1,9 +1,9 @@
 --- drupal-5.0/includes/theme.inc~	2007-01-26 13:09:14.801730081 +0200
 +++ drupal-5.0/includes/theme.inc	2007-01-26 13:09:52.242575644 +0200
-@@ -65,6 +65,7 @@
+@@ -65,6 +65,6 @@
      // File is a template/theme
      // Load its CSS, if it exists
-     if (file_exists($stylesheet = dirname($themes[$theme]->filename) .'/style.css')) {
+-    if (file_exists($stylesheet = dirname($themes[$theme]->filename) .'/style.css')) {
 +    if (file_exists('htdocs/' . ($stylesheet = dirname($themes[$theme]->filename) .'/style.css'))) {
        drupal_add_css($stylesheet, 'theme');
      }

================================================================
Index: SOURCES/drupal-topdir.patch
diff -u SOURCES/drupal-topdir.patch:1.2.2.2.2.1 SOURCES/drupal-topdir.patch:1.2.2.2.2.2
--- SOURCES/drupal-topdir.patch:1.2.2.2.2.1	Fri Jan 26 15:10:50 2007
+++ SOURCES/drupal-topdir.patch	Sun Feb 17 22:09:53 2008
@@ -18,3 +18,13 @@
  include_once './includes/bootstrap.inc';
  drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL);
  include_once './includes/xmlrpc.inc';
+--- drupal-5.7/update.php.old	2007-04-08 02:54:04.000000000 +0200
++++ drupal-5.7/update.php	2008-02-17 21:15:36.000000000 +0100
+@@ -765,6 +765,7 @@
+ // Our custom error handler is not yet installed, so we just suppress them.
+ ini_set('display_errors', FALSE);
+ 
++chdir('..');
+ include_once './includes/bootstrap.inc';
+ update_fix_system_table();
+ 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SOURCES/drupal-cron.patch?r1=1.5.2.2&r2=1.5.2.3&f=u
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SOURCES/drupal-sitesdir.patch?r1=1.2.2.1&r2=1.2.2.2&f=u
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SOURCES/drupal-themedir2.patch?r1=1.1.2.1&r2=1.1.2.2&f=u
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SOURCES/drupal-topdir.patch?r1=1.2.2.2.2.1&r2=1.2.2.2.2.2&f=u



More information about the pld-cvs-commit mailing list