Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Shouldnt the node_feed function use an alternate delivery callback?
$items['rss.xml'] = array(
'title' => 'RSS feed',
'page callback' => 'node_feed',
'access arguments' => array('access content'),
'type' => MENU_CALLBACK,
);
Now the drupal_deliver_html_page is used, while in the node_feed function the rendering process is terminated early to print the xml. Using an xml delivery callback would allow the rendering process to complete. This would be consistent with the page rendering system and allow other modules to alter the rendering.