diff options
Diffstat (limited to 'src/shared')
-rw-r--r-- | src/shared/utf8.c | 21 | ||||
-rw-r--r-- | src/shared/utf8.h | 2 |
2 files changed, 0 insertions, 23 deletions
diff --git a/src/shared/utf8.c b/src/shared/utf8.c index 98b68ef657..aedf6e29ea 100644 --- a/src/shared/utf8.c +++ b/src/shared/utf8.c @@ -184,27 +184,6 @@ char *ascii_is_valid(const char *str) { return (char*) str; } -char *ascii_filter(const char *str) { - const char *s; - char *r, *d; - size_t l; - - assert(str); - - l = strlen(str); - r = malloc(l + 1); - if (!r) - return NULL; - - for (s = str, d = r; *s; s++) - if ((unsigned char) *s < 128) - *(d++) = *s; - - *d = 0; - - return r; -} - char *utf16_to_utf8(const void *s, size_t length) { char *r; const uint8_t *f; diff --git a/src/shared/utf8.h b/src/shared/utf8.h index e3eef11bb9..f56077438a 100644 --- a/src/shared/utf8.h +++ b/src/shared/utf8.h @@ -30,8 +30,6 @@ char *ascii_is_valid(const char *s) _pure_; bool utf8_is_printable(const char* str, size_t length) _pure_; -char *ascii_filter(const char *s); - char *utf16_to_utf8(const void *s, size_t length); int utf8_encoded_valid_unichar(const char *str); |