diff --git a/modules/node/node.module b/modules/node/node.module index 65a4224cf3e8cc68e386a039c337dd5936b76b24..d3d1c85b1939a54eeab2c06b037cb1238a5e410e 100644 --- a/modules/node/node.module +++ b/modules/node/node.module @@ -1984,6 +1984,9 @@ function node_menu() { 'page callback' => 'node_feed', 'access arguments' => array('access content'), 'type' => MENU_CALLBACK, + // Pass a FALSE and array argument to ensure that additional path components + // are not passed to node_feed(). + 'page arguments' => array(FALSE, array()), ); // @todo Remove this loop when we have a 'description callback' property. // Reset internal static cache of _node_types_build(), forces to rebuild the diff --git a/modules/node/node.test b/modules/node/node.test index 7080ce7ab6e1d89c3d782314c4a3d0e8fc97983e..dc21daf6bc6976862d973924333b5849ab6d3ff3 100644 --- a/modules/node/node.test +++ b/modules/node/node.test @@ -832,7 +832,11 @@ class NodeRSSContentTestCase extends DrupalWebTestCase { // viewing node. $this->drupalGet("node/$node->nid"); $this->assertNoText($rss_only_content, t('Node content designed for RSS doesn\'t appear when viewing node.')); - + + // Check that the node feed page does not try to interpret additional path + // components as arguments for node_feed() and returns default content. + $this->drupalGet('rss.xml/' . $this->randomName() . '/' . $this->randomName()); + $this->assertText($rss_only_content, t('Ignore page arguments when delivering rss.xml.')); } }