X-Git-Url: https://code.citadel.org/?a=blobdiff_plain;f=webcit%2Fuserlist.c;h=176a175ebf5175d86f5aa4c540cd0277d0a8c7c6;hb=227c92b79dbb6aed6e4e0e045e4f2f63f77a7f2e;hp=6ed4be0c989ca9bf75d01e614bc10c61cfbf79b6;hpb=043963b7a2b834ba8825df8426327d25719165ee;p=citadel.git diff --git a/webcit/userlist.c b/webcit/userlist.c index 6ed4be0c9..176a175eb 100644 --- a/webcit/userlist.c +++ b/webcit/userlist.c @@ -38,8 +38,8 @@ void userlist(void) { char buf[SIZ]; char fl[SIZ]; - struct tm *tmbuf; - long lc; + struct tm tmbuf; + time_t lc; struct namelist *bio = NULL; struct namelist *bptr; int has_bio; @@ -100,11 +100,11 @@ void userlist(void) extract_long(buf, 2), extract_int(buf, 1)); lc = extract_long(buf, 3); - tmbuf = (struct tm *) localtime(&lc); + localtime_r(&lc, &tmbuf); wprintf("%02d/%02d/%04d ", - (tmbuf->tm_mon + 1), - tmbuf->tm_mday, - (tmbuf->tm_year + 1900)); + (tmbuf.tm_mon + 1), + tmbuf.tm_mday, + (tmbuf.tm_year + 1900)); wprintf("%ld%5ld\n",