Documentation Source Text

Check-in [363a0d0503]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fix date formats in the Last-Modified header.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 363a0d050309a4d56f541ccaf37237fc0ffc3e90
User & Date: drh 2016-08-31 10:07:06.743
Context
2016-08-31
16:53
Update the "fancyformat.tcl" script to use pages/hdom.tcl to parse html. (check-in: 78f2f948fb user: dan tags: trunk)
12:02
Use the experimental mobile-friendly menu. (check-in: b24301fa11 user: drh tags: mobile-friendly)
10:07
Fix date formats in the Last-Modified header. (check-in: 363a0d0503 user: drh tags: trunk)
07:00
Fix a build error in the previous commit. (check-in: 1e433b2be3 user: dan tags: trunk)
Changes
Unified Diff Ignore Whitespace Patch
Changes to misc/althttpd.c.
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
** Print a date tag in the header.  The name of the tag is zTag.
** The date is determined from the unix timestamp given.
*/
static int DateTag(const char *zTag, time_t t){
  struct tm *tm;
  char zDate[100];
  tm = gmtime(&t);
  strftime(zDate, sizeof(zDate), "%a, %d  %b %Y %H:%M:%S %z", tm);
  return printf("%s: %s\r\n", zTag, zDate);
}

/*
** Print the first line of a response followed by the server type.
*/
static void StartResponse(const char *zResultCode){







|







462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
** Print a date tag in the header.  The name of the tag is zTag.
** The date is determined from the unix timestamp given.
*/
static int DateTag(const char *zTag, time_t t){
  struct tm *tm;
  char zDate[100];
  tm = gmtime(&t);
  strftime(zDate, sizeof(zDate), "%a, %d %b %Y %H:%M:%S %z", tm);
  return printf("%s: %s\r\n", zTag, zDate);
}

/*
** Print the first line of a response followed by the server type.
*/
static void StartResponse(const char *zResultCode){