 includes/database/select.inc                |    2 +-
 includes/pager.inc                          |   68 ++++++++++----------------
 modules/simpletest/tests/database_test.test |    4 +-
 3 files changed, 29 insertions(+), 45 deletions(-)

diff --git includes/database/select.inc includes/database/select.inc
index fd3efd3..de0f04d 100644
--- includes/database/select.inc
+++ includes/database/select.inc
@@ -614,7 +614,7 @@ class SelectQueryExtender implements SelectQueryInterface {
     return $this->query->preExecute($query);
   }
 
-  public function execute() {
+  public final function execute() {
     // By calling preExecute() here, we force it to preprocess the extender
     // object rather than just the base query object.  That means
     // hook_query_alter() gets access to the extended object.
diff --git includes/pager.inc includes/pager.inc
index 12c9eed..fbcb79b 100644
--- includes/pager.inc
+++ includes/pager.inc
@@ -52,48 +52,6 @@ class PagerDefault extends SelectQueryExtender {
   }
 
   /**
-   * Override the execute method.
-   *
-   * Before we run the query, we need to add pager-based range() instructions
-   * to it.
-   */
-  public function execute() {
-    global $pager_page_array, $pager_total, $pager_total_items, $pager_limits;
-
-    // Add convenience tag to mark that this is an extended query. We have to
-    // do this in the constructor to ensure that it is set before preExecute()
-    // gets called.
-    if (!$this->preExecute($this)) {
-      return NULL;
-    }
-
-    // A NULL limit is the "kill switch" for pager queries.
-    if (empty($this->limit)) {
-      return;
-    }
-    $this->ensureElement();
-
-    $page = isset($_GET['page']) ? $_GET['page'] : '';
-
-    // Convert comma-separated $page to an array, used by other functions.
-    $pager_page_array = explode(',', $page);
-
-    if (!isset($pager_page_array[$this->element])) {
-      $pager_page_array[$this->element] = 0;
-    }
-
-    // We calculate the total of pages as ceil(items / limit).
-    $pager_total_items[$this->element] = $this->getCountQuery()->execute()->fetchField();
-    $pager_total[$this->element] = ceil($pager_total_items[$this->element] / $this->limit);
-    $pager_page_array[$this->element] = max(0, min((int)$pager_page_array[$this->element], ((int)$pager_total[$this->element]) - 1));
-    $pager_limits[$this->element] = $this->limit;
-    $this->range($pager_page_array[$this->element] * $this->limit, $this->limit);
-
-    // Now that we've added our pager-based range instructions, run the query normally.
-    return $this->query->execute();
-  }
-
-  /**
    * Ensure that there is an element associated with this query.
    *
    * After running this query, access $this->element to get the element for this
@@ -149,7 +107,33 @@ class PagerDefault extends SelectQueryExtender {
    *   value (FALSE, 0, NULL), the pager is disabled.
    */
   public function limit($limit = 10) {
+    global $pager_page_array, $pager_total, $pager_total_items, $pager_limits;
     $this->limit = $limit;
+    
+    // A NULL limit is the "kill switch" for pager queries.
+    if (empty($this->limit)) {
+      $this->range();
+      return;
+    }
+
+    $this->ensureElement();
+
+    $page = isset($_GET['page']) ? $_GET['page'] : '';
+
+    // Convert comma-separated $page to an array, used by other functions.
+    $pager_page_array = explode(',', $page);
+
+    if (!isset($pager_page_array[$this->element])) {
+      $pager_page_array[$this->element] = 0;
+    }
+
+    // We calculate the total of pages as ceil(items / limit).
+    $pager_total_items[$this->element] = $this->getCountQuery()->execute()->fetchField();
+    $pager_total[$this->element] = ceil($pager_total_items[$this->element] / $this->limit);
+    $pager_page_array[$this->element] = max(0, min((int)$pager_page_array[$this->element], ((int)$pager_total[$this->element]) - 1));
+    $pager_limits[$this->element] = $this->limit;
+    $this->range($pager_page_array[$this->element] * $this->limit, $this->limit);
+
     return $this;
   }
 
diff --git modules/simpletest/tests/database_test.test modules/simpletest/tests/database_test.test
index dc77d93..c1a4ef3 100644
--- modules/simpletest/tests/database_test.test
+++ modules/simpletest/tests/database_test.test
@@ -2062,7 +2062,7 @@ class DatabaseSelectPagerDefaultTestCase extends DatabaseTestCase {
     $query
       ->fields('t', array('age'))
       ->orderBy('age')
-      ->limit(5);
+      ->limit(3);
 
     $outer_query = db_select($query);
     $outer_query->addField('subquery', 'age');
@@ -2070,7 +2070,7 @@ class DatabaseSelectPagerDefaultTestCase extends DatabaseTestCase {
     $ages = $outer_query
       ->execute()
       ->fetchCol();
-    $this->assertEqual($ages, array(25, 26, 27, 28), t('Inner pager query returned the correct ages.'));
+    $this->assertEqual($ages, array(25, 26, 27), t('Inner pager query returned the correct ages.'));
   }
 
   /**
