Fossil SCM

Check-in [bdde964e06128a02] got the test for text/html exactly backwards.

drh 2023-06-23 22:15 trunk
Commit c6115dbf8326d66838e8d178c8b713797192e1e47c37646101f899c349a2f7a3
1 file changed +1 -1
+1 -1
--- src/cgi.c
+++ src/cgi.c
@@ -499,11 +499,11 @@
499499
assert( rangeEnd==0 );
500500
blob_appendf(&hdr, "Status: %d %s\r\n", iReplyStatus, zReplyStatus);
501501
}
502502
if( etag_tag()[0]!=0
503503
&& iReplyStatus==200
504
- && strcmp(zContentType,"text/html")==0
504
+ && strcmp(zContentType,"text/html")!=0
505505
){
506506
/* Do not cache HTML replies as those will have been generated and
507507
** will likely, therefore, contains a nonce and we want that nonce to
508508
** be different every time. */
509509
blob_appendf(&hdr, "ETag: %s\r\n", etag_tag());
510510
--- src/cgi.c
+++ src/cgi.c
@@ -499,11 +499,11 @@
499 assert( rangeEnd==0 );
500 blob_appendf(&hdr, "Status: %d %s\r\n", iReplyStatus, zReplyStatus);
501 }
502 if( etag_tag()[0]!=0
503 && iReplyStatus==200
504 && strcmp(zContentType,"text/html")==0
505 ){
506 /* Do not cache HTML replies as those will have been generated and
507 ** will likely, therefore, contains a nonce and we want that nonce to
508 ** be different every time. */
509 blob_appendf(&hdr, "ETag: %s\r\n", etag_tag());
510
--- src/cgi.c
+++ src/cgi.c
@@ -499,11 +499,11 @@
499 assert( rangeEnd==0 );
500 blob_appendf(&hdr, "Status: %d %s\r\n", iReplyStatus, zReplyStatus);
501 }
502 if( etag_tag()[0]!=0
503 && iReplyStatus==200
504 && strcmp(zContentType,"text/html")!=0
505 ){
506 /* Do not cache HTML replies as those will have been generated and
507 ** will likely, therefore, contains a nonce and we want that nonce to
508 ** be different every time. */
509 blob_appendf(&hdr, "ETag: %s\r\n", etag_tag());
510

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button