--- /usr/local/pkg/drupal/drupal-4.4.1/modules/system.module	2004-05-02 17:45:30.000000000 +0200
+++ modules/system.module	2004-05-20 23:18:26.000000000 +0200
@@ -112,7 +112,7 @@
   $group .= form_textfield(t("Anonymous user"), "anonymous", variable_get("anonymous", "Anonymous"), 70, 70, t("The name used to indicate anonymous users."));
   $group .= form_textfield(t("Default front page"), "site_frontpage", variable_get("site_frontpage", "node"), 70, 70, t("The home page displays content from this relative URL.  If you are not using clean URLs, specify the part after '?q='.  If unsure, specify 'node'."));
   $group .= form_textfield(t("Default 404 (not found) page"), "site_404", variable_get("site_404", ""), 70, 70, t("This page is displayed when no other content matches the requested document.  If you are not using clean URLs, specify the part after '?q='.  If unsure, specify nothing."));
-  $group .= form_radios(t("Clean URLs"), "clean_url", variable_get("clean_url", 0), array(t("Disabled"), t("Enabled")), t("Enable or disable clean URLs.  If enabled, you'll need <code>ModRewrite</code> support.  See also the <code>.htaccess</code> file in Drupal's top-level directory."));
+  $group .= form_radios(t("Clean URLs"), "clean_url", variable_get("clean_url", 0), array(t("Disabled"), t("Enabled"), t("Enabled unless URL contains special characters / or & (works around ModRewrite bug)")), t("Enable or disable clean URLs.  If enabled, you'll need <code>ModRewrite</code> support.  See also the <code>.htaccess</code> file in Drupal's top-level directory."));
 
   $output = form_group(t("General settings"), $group);
 
--- /usr/local/pkg/drupal/drupal-4.4.1/includes/common.inc	2004-05-02 17:45:29.000000000 +0200
+++ includes/common.inc	2004-05-20 23:47:06.000000000 +0200
@@ -1052,7 +1052,14 @@
 
   $base = ($absolute ? $base_url . '/' : '');
 
-  if (variable_get("clean_url", "0") == "0") {
+  $clean = variable_get("clean_url", "0");
+  if ($clean == "2") {
+    if (strpos($url,"%2F") !== false or strpos($url,"%26")) {
+      $clean = "0";
+    }
+  }
+
+  if ($clean == "0") {
     if (isset($url)) {
       if (isset($query)) {
         return "$base$script?q=$url&amp;$query$fragment";
