diff options
| author | Jörg Frings-Fürst <debian@jff.email> | 2026-03-08 17:28:50 +0100 |
|---|---|---|
| committer | Jörg Frings-Fürst <debian@jff.email> | 2026-03-08 17:28:50 +0100 |
| commit | ff33e1d252f46bec1a33e28700da3282fc24047a (patch) | |
| tree | 5c15bc695be820b393a8496c5807ecafbbdeb89b /lib/uninorm/u-normxfrm.h | |
| parent | b2ac982cc8b5290699eb5f52fb043d3d15e2624b (diff) | |
| parent | 5f59a34ab747dde8ede7357f3431bf06bd6002fe (diff) | |
Update upstream source from tag 'upstream/1.4.2'
Update to upstream version '1.4.2'
with Debian dir 493e96bcd865e4f9990e20bee26408c96231d727
Diffstat (limited to 'lib/uninorm/u-normxfrm.h')
| -rw-r--r-- | lib/uninorm/u-normxfrm.h | 22 |
1 files changed, 8 insertions, 14 deletions
diff --git a/lib/uninorm/u-normxfrm.h b/lib/uninorm/u-normxfrm.h index 92bf051e..deee268a 100644 --- a/lib/uninorm/u-normxfrm.h +++ b/lib/uninorm/u-normxfrm.h @@ -1,5 +1,5 @@ /* Locale dependent transformation for comparison of Unicode strings. - Copyright (C) 2009-2025 Free Software Foundation, Inc. + Copyright (C) 2009-2026 Free Software Foundation, Inc. Written by Bruno Haible <bruno@clisp.org>, 2009. This file is free software. @@ -27,24 +27,18 @@ char * FUNC (const UNIT *s, size_t n, uninorm_t nf, char *resultbuf, size_t *lengthp) { - UNIT normsbuf[2048 / sizeof (UNIT)]; - UNIT *norms; - size_t norms_length; - char convsbuf[2048]; - char *convs; - size_t convs_length; - char *result; - /* Normalize the Unicode string. */ - norms_length = sizeof (normsbuf) / sizeof (UNIT); - norms = U_NORMALIZE (nf, s, n, normsbuf, &norms_length); + UNIT normsbuf[2048 / sizeof (UNIT)]; + size_t norms_length = sizeof (normsbuf) / sizeof (UNIT); + UNIT *norms = U_NORMALIZE (nf, s, n, normsbuf, &norms_length); if (norms == NULL) /* errno is set here. */ return NULL; /* Convert it to locale encoding. */ - convs_length = sizeof (convsbuf) - 1; - convs = U_CONV_TO_ENCODING (locale_charset (), + char convsbuf[2048]; + size_t convs_length = sizeof (convsbuf) - 1; + char *convs = U_CONV_TO_ENCODING (locale_charset (), iconveh_error, norms, norms_length, NULL, @@ -77,7 +71,7 @@ FUNC (const UNIT *s, size_t n, uninorm_t nf, } /* Apply locale dependent transformations for comparison. */ - result = amemxfrm (convs, convs_length, resultbuf, lengthp); + char *result = amemxfrm (convs, convs_length, resultbuf, lengthp); if (result == NULL) { if (convs != convsbuf) |
