1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 21:07:34 +00:00

LibC: Implement wmemset

This commit is contained in:
Tim Schumacher 2021-09-22 10:22:24 +00:00 committed by Brian Gianforcaro
parent 485c0ef691
commit fa1208edfd
3 changed files with 33 additions and 0 deletions

View file

@ -393,4 +393,13 @@ wchar_t* wmemcpy(wchar_t* dest, const wchar_t* src, size_t n)
return dest;
}
wchar_t* wmemset(wchar_t* wcs, wchar_t wc, size_t n)
{
for (size_t i = 0; i < n; i++) {
wcs[i] = wc;
}
return wcs;
}
}

View file

@ -45,5 +45,6 @@ wchar_t* wcspbrk(const wchar_t*, const wchar_t*);
wchar_t* wcsstr(const wchar_t*, const wchar_t*);
wchar_t* wmemchr(const wchar_t*, wchar_t, size_t);
wchar_t* wmemcpy(wchar_t*, const wchar_t*, size_t);
wchar_t* wmemset(wchar_t*, wchar_t, size_t);
__END_DECLS