- Electron version: 1.2.0
- Operating system: OS X

``` js
electron.protocol.registerStandardSchemes(['foobar', 'http', 'https']);

app.on('ready', function() {
  electron.protocol.registerHttpProtocol('foobar', (request, callback) => {
    const redirectPath = `http://www.google.com`;
    callback({ method: request.method, referrer: request.referrer, url: redirectPath });
  }, e => { if (e) { console.log(e); } });
});
```

A webview somewhere gets its src set to "foobar://baz", however a blank window appears. The page is perpetually in a load state, as only the `did-start-loading` and `did-get-response-details` events get triggered on the webview.

If I redirect to `http://localhost:{port}/foobar`, my server does receive the request and responds properly. However, the webview in electron is still blank. Loading that address in a different browser works as expected.

What am I missing? Is there something more I need to do to get `registerHttpProtocol` working?

atom/browser/net/url_request_fetch_job.cc
public:
  explicit ResponsePiper(URLRequestFetchJob* job)
      : first_write_(true), job_(job) {}
  
  int Initialize(const net::CompletionCallback& callback) override {
    return net::OK;
  }
  int Write(net::IOBuffer* buffer,
            int num_bytes,
            const net::CompletionCallback& callback) override {
    if (first_write_) {
      
      
      job_->HeadersCompleted();
      first_write_ = false;
    }
    return job_->DataAvailable(buffer, num_bytes);
  }
  int Finish(const net::CompletionCallback& callback) override {
    return net::OK;
  }
 private:
  bool first_write_;
  URLRequestFetchJob* job_;
  DISALLOW_COPY_AND_ASSIGN(ResponsePiper);
};
}  
URLRequestFetchJob::URLRequestFetchJob(