summaryrefslogtreecommitdiff
path: root/math/math.c
diff options
context:
space:
mode:
Diffstat (limited to 'math/math.c')
-rw-r--r--math/math.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/math/math.c b/math/math.c
index ba0309d..0388ee5 100644
--- a/math/math.c
+++ b/math/math.c
@@ -208,6 +208,7 @@ pr_record(struct meta *mp, size_t n, enum sorder curso)
{
int i = 0;
char *uri, *p;
+ struct author a;
uri = getenv("REQUEST_URI");
@@ -236,7 +237,7 @@ pr_record(struct meta *mp, size_t n, enum sorder curso)
pr_opts(mp);
puts("</td>");
printf("<td>%s</td>\n", ctime(&mp->date));
- printf("<td>%s</td></tr>\n", mp->author);
+ printf("<td>%s</td></tr>\n", db_getauthor(&a, mp->author) ? a.name : mp->author);
}
}
@@ -331,6 +332,7 @@ main(int argc, char **argv)
enum jflag jf;
enum sorder so;
char *q, *srchq, *lang;
+ struct author a;
sname = getenv("SCRIPT_NAME");
@@ -472,7 +474,7 @@ main(int argc, char **argv)
printf("<p>%s</p>\n", curr->abstract);
puts("<p>");
- printf("Author: %s<br />\n", curr->author);
+ printf("Author: %s<br />\n", db_getauthor(&a, curr->author) ? a.name : curr->author);
printf("Date: %s<br />\n", ctime(&curr->date));
printf("Language: ");
lang = pr_lang(curr->language);