home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Fresh Fish 9
/
FreshFishVol9-CD2.bin
/
bbs
/
gnu
/
libnix-0.8-src.lha
/
libnix-0.8
/
sources
/
nix
/
stdio
/
mblen.c
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
Macintosh to JP
NeXTSTEP
RISC OS/Acorn
Shift JIS
UTF-8
Wrap
C/C++ Source or Header
|
1994-12-12
|
306 b
|
13 lines
#include <stdlib.h>
/* Sorry, the Amiga OS locale currently doesn't support
* character sets other than ECMA Latin 1, so this is
* just a "C" locale function
*/
int mblen(const char *s,size_t n)
{ size_t l=0;
while(n--&&*s++)
l++;
return sizeof(wchar_t)*(l+1); /* 1 for the NUL character */
}