From 848dd4199383e89ab036ececb94e6431adc684d7 Mon Sep 17 00:00:00 2001 From: Julien BLACHE Date: Tue, 2 Feb 2010 21:05:32 +0100 Subject: [PATCH] serve_file() is broken due to evbuffer_read() If we ever need to serve files for a web interface or otherwise, serve_file() will need to be fixed to not use evbuffer_read(). --- src/httpd.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/httpd.c b/src/httpd.c index 7e015e1c..997e3a8e 100644 --- a/src/httpd.c +++ b/src/httpd.c @@ -760,6 +760,9 @@ serve_file(struct evhttp_request *req, char *uri) return; } + /* FIXME: this is broken, if we ever need to serve files here, + * this must be fixed. + */ ret = evbuffer_read(evbuf, fd, sb.st_size); close(fd); if (ret < 0)