| 473 |
time_t time_online; |
time_t time_online; |
| 474 |
struct tm *tm_online; |
struct tm *tm_online; |
| 475 |
char msg_f[21]; |
char msg_f[21]; |
| 476 |
int truncate; |
int eol; |
| 477 |
int msg_len; |
int msg_len; |
| 478 |
int len; |
int len; |
| 479 |
int len_username; |
int len_username; |
| 483 |
strncpy(msg_f, msg, sizeof(msg_f) - 1); |
strncpy(msg_f, msg, sizeof(msg_f) - 1); |
| 484 |
msg_f[sizeof(msg_f) - 1] = '\0'; |
msg_f[sizeof(msg_f) - 1] = '\0'; |
| 485 |
|
|
| 486 |
len = split_line(msg_f, 20, &truncate, &msg_len); |
len = split_line(msg_f, 20, &eol, &msg_len); |
| 487 |
if (truncate) |
msg_f[len] = '\0'; |
|
{ |
|
|
log_error("Status string is truncated\n"); |
|
|
msg_f[len] = '\0'; |
|
|
} |
|
| 488 |
|
|
| 489 |
len_username = (int)strnlen(BBS_username, sizeof(BBS_username)); |
len_username = (int)strnlen(BBS_username, sizeof(BBS_username)); |
| 490 |
|
|