diff --git a/core/modules/node/lib/Drupal/node/Tests/NodeRSSContentTest.php b/core/modules/node/lib/Drupal/node/Tests/NodeRSSContentTest.php index 97b3b252a8f8b51b191ca7f672ea018833f7a8a2..c0768a2013e95680b39262b175c719f9697fc884 100644 --- a/core/modules/node/lib/Drupal/node/Tests/NodeRSSContentTest.php +++ b/core/modules/node/lib/Drupal/node/Tests/NodeRSSContentTest.php @@ -74,5 +74,9 @@ function testNodeRSSContent() { $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.')); } } diff --git a/core/modules/node/node.module b/core/modules/node/node.module index 7d84b9dd1aacba58c7b63ccaa1143c0f796a17cb..b18b8f4d0caaba3ab0afff9c11c5c533c15111ed 100644 --- a/core/modules/node/node.module +++ b/core/modules/node/node.module @@ -1901,6 +1901,9 @@ function node_menu() { $items['rss.xml'] = array( 'title' => 'RSS feed', 'page callback' => 'node_feed', + // Pass a FALSE and array argument to ensure that additional path components + // are not passed to node_feed(). + 'page arguments' => array(FALSE, array()), 'access arguments' => array('access content'), 'type' => MENU_CALLBACK, );