diff options
Diffstat (limited to 'pages/content.ecpp')
-rw-r--r-- | pages/content.ecpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/pages/content.ecpp b/pages/content.ecpp index 5f1780a..9fdabf3 100644 --- a/pages/content.ecpp +++ b/pages/content.ecpp @@ -26,6 +26,8 @@ reply.setContentType(mime); // FileCache::ptr_type f = LiveFileCache().get("/tmp/live/" + request.getPathInfo()); string const path(request.getPathInfo()); +// dsyslog("vdrlive::content: path = %s", path.c_str()); + FileCache::ptr_type f; string const epgImgPath(LiveSetup().GetEpgImageDir()); @@ -33,17 +35,22 @@ if (!epgImgPath.empty() && path.find(epgImgPath) != string::npos) { f = LiveFileCache().get(path); } else { + // dsyslog("vdrlive::content: retrieve from %s", Plugin::GetConfigDirectory().c_str()); f = LiveFileCache().get(Plugin::GetConfigDirectory() + "/" + path); } if (f.get() == 0) { + // dsyslog("vdrlive::content: DECLINED"); return DECLINED; } string ctime = tnt::HttpMessage::htdate(f->ctime()); string browserTime = request.getHeader(tnt::httpheader::ifModifiedSince); -if (browserTime == ctime) +if (browserTime == ctime) { + // dsyslog("vdrlive::content: HTTP_NOT_MODIFIED"); return HTTP_NOT_MODIFIED; +} +// dsyslog("vdrlive::content: send %d bytes of data", f->size()); reply.setHeader(tnt::httpheader::lastModified, ctime); reply.out().write(f->data(), f->size()); </%cpp> |