aboutsummaryrefslogtreecommitdiff
path: root/newlib/libc/stdlib/mbsrtowcs.c
blob: 48d36d028ea0bf66694fee701204f6343cb9ada1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
/* doc in mbsnrtowcs.c */

#include <reent.h>
#include <newlib.h>
#include <wchar.h>
#include <stdlib.h>
#include <stdio.h>
#include <errno.h>

size_t
_DEFUN (_mbsrtowcs_r, (r, dst, src, len, ps), 
	struct _reent *r,
	wchar_t *dst,
	const char **src,
	size_t len,
	mbstate_t *ps)
{
  return _mbsnrtowcs_r (r, dst, src, (size_t) -1, len, ps);
}

#ifndef _REENT_ONLY
size_t
_DEFUN (mbsrtowcs, (dst, src, len, ps),
	wchar_t *__restrict dst,
	const char **__restrict src,
	size_t len,
	mbstate_t *__restrict ps)
{
  return _mbsnrtowcs_r (_REENT, dst, src, (size_t) -1, len, ps);
}
#endif /* !_REENT_ONLY */