diff options
author | kcwu <kcwu@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2005-03-19 20:59:50 +0800 |
---|---|---|
committer | kcwu <kcwu@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2005-03-19 20:59:50 +0800 |
commit | 15135e4525a4294ce016f87e85841e7d3ec2164b (patch) | |
tree | c88bdd5afd05c2b5c5d08984b87fe103ec96cd9c /mbbsd/io.c | |
parent | 7c0c9404b7353ca9c4bf08b0b9a3226554ea8031 (diff) | |
download | pttbbs-15135e4525a4294ce016f87e85841e7d3ec2164b.tar pttbbs-15135e4525a4294ce016f87e85841e7d3ec2164b.tar.gz pttbbs-15135e4525a4294ce016f87e85841e7d3ec2164b.tar.bz2 pttbbs-15135e4525a4294ce016f87e85841e7d3ec2164b.tar.lz pttbbs-15135e4525a4294ce016f87e85841e7d3ec2164b.tar.xz pttbbs-15135e4525a4294ce016f87e85841e7d3ec2164b.tar.zst pttbbs-15135e4525a4294ce016f87e85841e7d3ec2164b.zip |
add 'const' qualifiers on function parameters.
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@2632 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/io.c')
-rw-r--r-- | mbbsd/io.c | 14 |
1 files changed, 7 insertions, 7 deletions
@@ -54,7 +54,7 @@ init_buf(void) memset(inbuf, 0, IBUFSIZE); } void -output(char *s, int len) +output(const char *s, int len) { /* Invalid if len >= OBUFSIZE */ @@ -433,7 +433,7 @@ igetch(void) * NO_RELOAD: ¤£ strip (?) */ int -strip_ansi(char *buf, char *str, int mode) +strip_ansi(char *buf, const char *str, int mode) { register int count = 0; static const char EscapeFlag[] = { @@ -463,7 +463,7 @@ strip_ansi(char *buf, char *str, int mode) *buf++ = *str; ++count; }else{ - register char* p = str + 1; + const char* p = str + 1; if( *p != '[' ){ ++str; continue; @@ -528,7 +528,7 @@ strip_nonebig5(unsigned char *str, int maxlen) } int -oldgetdata(int line, int col, char *prompt, char *buf, int len, int echo) +oldgetdata(int line, int col, const char *prompt, char *buf, int len, int echo) { register int ch, i; int clen; @@ -679,14 +679,14 @@ oldgetdata(int line, int col, char *prompt, char *buf, int len, int echo) /* Ptt */ int -getdata_buf(int line, int col, char *prompt, char *buf, int len, int echo) +getdata_buf(int line, int col, const char *prompt, char *buf, int len, int echo) { return oldgetdata(line, col, prompt, buf, len, echo); } int -getdata_str(int line, int col, char *prompt, char *buf, int len, int echo, char *defaultstr) +getdata_str(int line, int col, const char *prompt, char *buf, int len, int echo, const char *defaultstr) { strlcpy(buf, defaultstr, len); @@ -694,7 +694,7 @@ getdata_str(int line, int col, char *prompt, char *buf, int len, int echo, char } int -getdata(int line, int col, char *prompt, char *buf, int len, int echo) +getdata(int line, int col, const char *prompt, char *buf, int len, int echo) { buf[0] = 0; return oldgetdata(line, col, prompt, buf, len, echo); |