Chris Walker reports a silly typo in HTML reporting: the < and > signs
[sgt/agedu] / html.c
diff --git a/html.c b/html.c
index 7f82f39..ad23159 100644 (file)
--- a/html.c
+++ b/html.c
@@ -869,7 +869,10 @@ char *html_query(const void *t, unsigned long index,
 
     path = snewn(1+trie_maxpathlen(t), char);
     ctx->path2 = path2 = snewn(1+trie_maxpathlen(t), char);
-    ctx->oururi = format_string(cfg->uriformat, index, t);
+    if (cfg->uriformat)
+        ctx->oururi = format_string(cfg->uriformat, index, t);
+    else
+        ctx->oururi = NULL;
 
     /*
      * HEAD section.
@@ -956,10 +959,10 @@ char *html_query(const void *t, unsigned long index,
        char buf[80];
 
        if (i == 0) {
-           strcpy(buf, "&lt; ");
+           strcpy(buf, "&gt; ");
            round_and_format_age(ctx, ctx->thresholds[0], buf+5, 0);
        } else if (i == MAXCOLOUR) {
-           strcpy(buf, "&gt; ");
+           strcpy(buf, "&lt; ");
            round_and_format_age(ctx, ctx->thresholds[MAXCOLOUR-1], buf+5, 0);
        } else {
            unsigned long long midrange =