magento/magento2 — pull request #37 by colinmollenhour (2012-07-04 19:38:13+00:00)
Title: Add method to prevent sending of response after action completes

Magento needs some way for a controller action to output and then signal the router to *not* attempt to send headers. There are cases like the wysiwyg thumbnails that generate "HEADERS ALREADY SENT" errors in the logs because the headers were sent by dynamic image output. I manually added an "exit;" inside the controllers to prevent this in production but there should be a more graceful solution since "exit;" prevents the use of event observers that are dispatched after the controller action. For example:

```
$this->getResponse()->disableOutput();
```