summaryrefslogtreecommitdiffstats
path: root/lib/libc/locale/ascii.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libc/locale/ascii.c')
-rw-r--r--lib/libc/locale/ascii.c23
1 files changed, 14 insertions, 9 deletions
diff --git a/lib/libc/locale/ascii.c b/lib/libc/locale/ascii.c
index 493bf42..784814d 100644
--- a/lib/libc/locale/ascii.c
+++ b/lib/libc/locale/ascii.c
@@ -6,6 +6,11 @@
* This code is derived from software contributed to Berkeley by
* Paul Borman at Krystal Technologies.
*
+ * Copyright (c) 2011 The FreeBSD Foundation
+ * All rights reserved.
+ * Portions of this software were developed by David Chisnall
+ * under sponsorship from the FreeBSD Foundation.
+ *
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
@@ -56,17 +61,17 @@ static size_t _ascii_wcsnrtombs(char * __restrict, const wchar_t ** __restrict,
size_t, size_t, mbstate_t * __restrict);
int
-_ascii_init(_RuneLocale *rl)
+_ascii_init(struct xlocale_ctype *l,_RuneLocale *rl)
{
- __mbrtowc = _ascii_mbrtowc;
- __mbsinit = _ascii_mbsinit;
- __mbsnrtowcs = _ascii_mbsnrtowcs;
- __wcrtomb = _ascii_wcrtomb;
- __wcsnrtombs = _ascii_wcsnrtombs;
- _CurrentRuneLocale = rl;
- __mb_cur_max = 1;
- __mb_sb_limit = 128;
+ l->__mbrtowc = _ascii_mbrtowc;
+ l->__mbsinit = _ascii_mbsinit;
+ l->__mbsnrtowcs = _ascii_mbsnrtowcs;
+ l->__wcrtomb = _ascii_wcrtomb;
+ l->__wcsnrtombs = _ascii_wcsnrtombs;
+ l->runes = rl;
+ l->__mb_cur_max = 1;
+ l->__mb_sb_limit = 128;
return(0);
}
OpenPOWER on IntegriCloud