/[LeafOK_CVS]/lbbs/src/test_bbs.c
ViewVC logotype

Annotation of /lbbs/src/test_bbs.c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.6 - (hide annotations)
Sat Jan 3 10:27:14 2026 UTC (2 months, 1 week ago) by sysadm
Branch: MAIN
CVS Tags: HEAD
Changes since 1.5: +1 -1 lines
Content type: text/x-csrc
Update copyright info

1 sysadm 1.3 /* SPDX-License-Identifier: GPL-3.0-or-later */
2     /*
3     * test_bbs
4     * - tester for BBS related common functions
5     *
6 sysadm 1.6 * Copyright (C) 2004-2026 Leaflet <leaflet@leafok.com>
7 sysadm 1.3 */
8 sysadm 1.1
9 sysadm 1.5 #ifdef HAVE_CONFIG_H
10     #include "config.h"
11     #endif
12    
13 sysadm 1.1 #include "bbs.h"
14     #include <stdio.h>
15    
16     int main(int argc, char *argv[])
17     {
18     int i;
19 sysadm 1.2 int user_level;
20 sysadm 1.1
21     const int user_points[] = {
22     -50, -1, 0, 1, 49, 50, 51, 499, 500, 501, 99999, 100000, 100001};
23    
24     const int user_cnt = sizeof(user_points) / sizeof(int);
25    
26     for (i = 0; i < user_cnt; i++)
27     {
28 sysadm 1.2 user_level = get_user_level(user_points[i]);
29     printf("%10d\t%d\t%s\n", user_points[i], user_level, get_user_level_name(user_level));
30 sysadm 1.1 }
31    
32     return 0;
33     }

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1