Index: includes/batch.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/batch.inc,v
retrieving revision 1.42
diff -u -p -r1.42 batch.inc
--- includes/batch.inc	15 Oct 2009 16:18:44 -0000	1.42
+++ includes/batch.inc	21 Oct 2009 23:49:59 -0000
@@ -109,11 +109,15 @@ function _batch_progress_page_js() {
   $current_set = _batch_current_set();
   drupal_set_title($current_set['title'], PASS_THROUGH);
 
+  // Merge required query parameters for batch processing into those provided by
+  // batch_set() or hook_batch_alter().
+  $batch['url_options']['query']['id'] = $batch['id'];
+
   $js_setting = array(
     'batch' => array(
       'errorMessage' => $current_set['error_message'] . '<br />' . $batch['error_message'],
       'initMessage' => $current_set['init_message'],
-      'uri' => url($batch['url'], array('query' => array('id' => $batch['id']))),
+      'uri' => url($batch['url'], $batch['url_options']),
     ),
   );
   drupal_add_js($js_setting, 'setting');
@@ -189,7 +193,12 @@ function _batch_progress_page_nojs() {
     ob_end_clean();
   }
 
-  $url = url($batch['url'], array('query' => array('id' => $batch['id'], 'op' => $new_op)));
+  // Merge required query parameters for batch processing into those provided by
+  // batch_set() or hook_batch_alter().
+  $batch['url_options']['query']['id'] = $batch['id'];
+  $batch['url_options']['query']['op'] = $new_op;
+
+  $url = url($batch['url'], $batch['url_options']);
   drupal_add_html_head('<meta http-equiv="Refresh" content="0; URL=' . $url . '">');
 
   return theme('progress_bar', array('percent' => $percentage, 'message' => $message));
Index: includes/form.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/form.inc,v
retrieving revision 1.386
diff -u -p -r1.386 form.inc
--- includes/form.inc	16 Oct 2009 19:20:34 -0000	1.386
+++ includes/form.inc	21 Oct 2009 23:49:59 -0000
@@ -2963,7 +2963,9 @@ function _form_set_class(&$element, $cla
  *       'operations' and 'finished' functions, for instance if they don't
  *       reside in the original '.module' file. The path should be relative to
  *       the base_path(), and thus should be built using drupal_get_path().
- *     'css' : an array of paths to CSS files to be used on the progress page.
+ *     'css': an array of paths to CSS files to be used on the progress page.
+ *     'url_options': options passed to url() when constructing redirect
+ *       URLs for the batch.
  *
  * Operations are added as new batch sets. Batch sets are used to ensure
  * clean code independence, ensuring that several batches submitted by
@@ -3051,6 +3053,7 @@ function batch_process($redirect = NULL,
       'current_set' => 0,
       'progressive' => TRUE,
       'url' => $url,
+      'url_options' => array(),
       'source_page' => $_GET['q'],
       'redirect' => $redirect,
       'theme' => $GLOBALS['theme_key'],
Index: misc/drupal.js
===================================================================
RCS file: /cvs/drupal/drupal/misc/drupal.js,v
retrieving revision 1.58
diff -u -p -r1.58 drupal.js
--- misc/drupal.js	31 Aug 2009 05:51:07 -0000	1.58
+++ misc/drupal.js	21 Oct 2009 23:49:59 -0000
@@ -344,4 +344,11 @@ Drupal.theme.prototype = {
   }
 };
 
+/**
+ * Return whether the given variable is an object.
+ */
+Drupal.isObject = function(value) {
+  return (value !== null && typeof value === 'object');
+};
+
 })(jQuery);
Index: misc/tableheader.js
===================================================================
RCS file: /cvs/drupal/drupal/misc/tableheader.js,v
retrieving revision 1.27
diff -u -p -r1.27 tableheader.js
--- misc/tableheader.js	20 Sep 2009 19:14:40 -0000	1.27
+++ misc/tableheader.js	21 Oct 2009 23:49:59 -0000
@@ -18,8 +18,9 @@ Drupal.behaviors.tableHeader = {
     var headers = [];
 
     $('table.sticky-enabled thead', context).once('tableheader', function () {
-      // Clone thead so it inherits original jQuery properties.
-      var headerClone = $(this).clone(true).insertBefore(this.parentNode).wrap('<table class="sticky-header"></table>').parent().css({
+      // Clone the table header so it inherits original jQuery properties. Hide
+      // the table to avoid a flash of the header clone upon page load.
+      var headerClone = $(this).clone(true).hide().insertBefore(this.parentNode).wrap('<table class="sticky-header"></table>').parent().css({
         position: 'fixed',
         top: '0px'
       });
@@ -32,6 +33,9 @@ Drupal.behaviors.tableHeader = {
       headerClone.table = table;
       // Finish initializing header positioning.
       tracker(headerClone);
+      // We hid the header to avoid it showing up erroneously on page load;
+      // we need to unhide it now so that it will show up when expected.
+      $(headerClone).children('thead').show();
 
       $(table).addClass('sticky-table');
     });
Index: modules/locale/locale.test
===================================================================
RCS file: /cvs/drupal/drupal/modules/locale/locale.test,v
retrieving revision 1.48
diff -u -p -r1.48 locale.test
--- modules/locale/locale.test	17 Oct 2009 05:50:28 -0000	1.48
+++ modules/locale/locale.test	21 Oct 2009 23:49:59 -0000
@@ -237,7 +237,7 @@ class LocaleTranslationFunctionalTest ex
     $this->clickLink(t('edit'));
     // We save the lid from the path.
     $matches = array();
-    preg_match('!admin/config/regional/translate/edit/(\d)+!', $this->getUrl(), $matches);
+    preg_match('!admin/config/regional/translate/edit/(\d+)!', $this->getUrl(), $matches);
     $lid = $matches[1];
     // No t() here, it's surely not translated yet.
     $this->assertText($name, t('name found on edit screen.'));
Index: modules/shortcut/shortcut.admin.inc
===================================================================
RCS file: /cvs/drupal/drupal/modules/shortcut/shortcut.admin.inc,v
retrieving revision 1.1
diff -u -p -r1.1 shortcut.admin.inc
--- modules/shortcut/shortcut.admin.inc	17 Oct 2009 00:51:52 -0000	1.1
+++ modules/shortcut/shortcut.admin.inc	21 Oct 2009 23:49:59 -0000
@@ -519,18 +519,21 @@ function shortcut_link_delete_submit($fo
  *   Returned from shortcut_set_load().
  */
 function shortcut_link_add_inline($shortcut_set) {
-  if (isset($_REQUEST['token']) && drupal_valid_token($_REQUEST['token'], 'shortcut-add-link') && shortcut_valid_link($_GET['link'])) {
-    $link = array(
-      'link_title' => $_GET['name'],
-      'link_path' => $_GET['link'],
-    );
-    shortcut_admin_add_link($link, $shortcut_set, shortcut_max_slots());
-    if (shortcut_set_save($shortcut_set)) {
-      drupal_set_message(t('Added a shortcut for %title.', array('%title' => $link['link_title'])));
-    }
-    else {
-      drupal_set_message(t('Unable to add a shortcut for %title.', array('%title' => $link['link_title'])));
+  if (isset($_REQUEST['token']) && drupal_valid_token($_REQUEST['token'], 'shortcut-add-link')) {
+    // Get rid of any possible query string values which might be on the URL.
+    list($link_path) = explode('?', $_GET['link']);
+    if (shortcut_valid_link($link_path)) {
+      $link = array(
+        'link_title' => $_GET['name'],
+        'link_path' => $link_path,
+      );
+      shortcut_admin_add_link($link, $shortcut_set, shortcut_max_slots());
+      if (shortcut_set_save($shortcut_set)) {
+        drupal_set_message(t('Added a shortcut for %title.', array('%title' => $link['link_title'])));
+        drupal_goto();
+      }
     }
+    drupal_set_message(t('Unable to add a shortcut for %title.', array('%title' => $link['link_title'])));
     drupal_goto();
   }
   return drupal_access_denied();
Index: modules/toolbar/toolbar.tpl.php
===================================================================
RCS file: /cvs/drupal/drupal/modules/toolbar/toolbar.tpl.php,v
retrieving revision 1.5
diff -u -p -r1.5 toolbar.tpl.php
--- modules/toolbar/toolbar.tpl.php	17 Oct 2009 00:51:53 -0000	1.5
+++ modules/toolbar/toolbar.tpl.php	21 Oct 2009 23:50:00 -0000
@@ -6,15 +6,23 @@
  * Default template for admin toolbar.
  *
  * Available variables:
+ * - $classes: String of classes that can be used to style contextually through
+ *   CSS. It can be manipulated through the variable $classes_array from
+ *   preprocess functions. The default value has the following:
+ *   - toolbar: The current template type, i.e., "theming hook".
  * - $toolbar['toolbar_user']: User account / logout links.
  * - $toolbar['toolbar_menu']: Top level management menu links.
  * - $toolbar['toolbar_drawer']: A place for extended toolbar content.
  *
+ * Other variables:
+ * - $classes_array: Array of html class attribute values. It is flattened
+ *   into a string within the variable $classes.
+ *
  * @see template_preprocess()
- * @see template_preprocess_admin_toolbar()
+ * @see template_preprocess_toolbar()
  */
 ?>
-<div id="toolbar" class="clearfix">
+<div id="toolbar" class="<?php print $classes; ?> clearfix">
   <div class="toolbar-menu clearfix">
     <?php if ($toolbar['toolbar_drawer']):?>
       <span class="toggle toggle-active"><?php print t('Open'); ?></span>
