commit 86359dd

grunfink  ·  2026-02-03 07:18:59 +0000 UTC
parent 8048ef2
Call xs_replace_i() in html_date_label() instead of overwriting.
1 files changed,  +2, -2
M html.c
M html.c
+2, -2
 1@@ -234,8 +234,8 @@ xs_str *html_date_label(snac *user, const char *date)
 2             /* copy the 3letter translated month name */
 3             const char *m = L(months[tm.tm_mon]);
 4 
 5-            if (xs_is_string(m) && strlen(m) >= 3)
 6-                memcpy(date, m, 3);
 7+            if (xs_is_string(m))
 8+                date = xs_replace_i(date, months[tm.tm_mon], m);
 9         }
10 
11         return date;