aboutsummaryrefslogtreecommitdiff
path: root/cforum.c
diff options
context:
space:
mode:
authorJohn Ankarström <john@ankarstrom.se>2021-09-17 22:34:52 +0200
committerJohn Ankarström <john@ankarstrom.se>2021-09-17 22:34:52 +0200
commit56509ab16c8d2225182eb0400e5c6a4900870391 (patch)
treee3c3bcc760ecc187a3f4ee8c6616855d15e86d83 /cforum.c
parent3e400c3df5572524b7ba08b030f45eb3ba6b7734 (diff)
downloadcforum-56509ab16c8d2225182eb0400e5c6a4900870391.tar.gz
Fix mktpl bug
Diffstat (limited to 'cforum.c')
-rw-r--r--cforum.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/cforum.c b/cforum.c
index f29d423..19dee61 100644
--- a/cforum.c
+++ b/cforum.c
@@ -70,7 +70,7 @@ main(int argc, char *argv[])
}
/* Parse query string. */
- postid = userid = -1;
+ postid = userid = 0;
while(p = nextparam(GET, 128)){
v = split(p);
if(strcmp(p, "post") == 0) postid = atoi(v);
@@ -78,9 +78,9 @@ main(int argc, char *argv[])
}
/* Handle request. */
- if(postid != -1)
+ if(postid)
showpost(postid);
- else if(userid != -1)
+ else if(userid)
showuser(userid);
else
showfront();