Software /
code /
prosody
Diff
plugins/mod_http_files.lua @ 10776:8f3b87eaec49 0.11
mod_http_files: Avoid using inode in etag, fix #1498
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sat, 25 Apr 2020 20:55:00 +0200 |
parent | 9463:f7530c846f98 |
child | 10778:a62b981db0e2 |
line wrap: on
line diff
--- a/plugins/mod_http_files.lua Thu Apr 23 13:44:47 2020 +0100 +++ b/plugins/mod_http_files.lua Sat Apr 25 20:55:00 2020 +0200 @@ -112,7 +112,7 @@ local last_modified = os_date('!%a, %d %b %Y %H:%M:%S GMT', attr.modification); response_headers.last_modified = last_modified; - local etag = ('"%02x-%x-%x-%x"'):format(attr.dev or 0, attr.ino or 0, attr.size or 0, attr.modification or 0); + local etag = ('"%x-%x-%x"'):format(attr.change or 0, attr.size or 0, attr.modification or 0); response_headers.etag = etag; local if_none_match = request_headers.if_none_match