summaryrefslogtreecommitdiffstats
path: root/common/bbs/string.c
blob: 60b03b372cd2a79ff132f0ddf65ac2eac65fdf47 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "cmbbs.h"

void obfuscate_ipstr(char *s)
{
    s = strrchr(s, '.');
    if (!s) return;
    if (!*++s) return;
    // s points to a.'b'
    *s++ = '*';
    *s = 0;
}