Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ include (utils.cmake)
disallow_intree_builds()

# API version - be sure to update utf8proc.h and Makefile, too!
project (utf8proc VERSION 2.11.0 LANGUAGES C)
project (utf8proc VERSION 2.11.1 LANGUAGES C)

# This is the ABI version number, which may differ from the
# API version number (defined in utf8proc.h and above).
# Be sure to also update these in Makefile and MANIFEST!
set(SO_MAJOR 3)
set(SO_MINOR 2)
set(SO_PATCH 0)
set(SO_PATCH 1)

option(UTF8PROC_INSTALL "Enable installation of utf8proc" On)
option(UTF8PROC_ENABLE_TESTING "Enable testing of utf8proc" Off)
Expand Down
6 changes: 3 additions & 3 deletions MANIFEST
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ include/
include/utf8proc.h
lib/
lib/libutf8proc.a
lib/libutf8proc.so -> libutf8proc.so.3.2.0
lib/libutf8proc.so.2 -> libutf8proc.so.3.2.0
lib/libutf8proc.so.3.2.0
lib/libutf8proc.so -> libutf8proc.so.3.2.1
lib/libutf8proc.so.2 -> libutf8proc.so.3.2.1
lib/libutf8proc.so.3.2.1
lib/pkgconfig/
lib/pkgconfig/libutf8proc.pc
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ SOFLAG = -Wl,-soname
# Be sure to also update these ABI versions in MANIFEST and CMakeLists.txt!
MAJOR=3
MINOR=2
PATCH=0
PATCH=1

# api version (also in utf8proc.h and CMakeLists.txt)
VERSION=2.11.0
VERSION=2.11.1

OS := $(shell uname)
ifeq ($(OS),Darwin) # MacOS X
Expand Down
6 changes: 6 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# utf8proc release history #

## Version 2.11.1 ##

2025-11-04

- Correct out-of-bounds memory access when calling `utf8proc_map` with both `UTF8PROC_CHARBOUND` and `UTF8PROC_DECOMPOSE` ([#311]).

## Version 2.11.0 ##

2025-09-10
Expand Down
5 changes: 4 additions & 1 deletion test/fuzzer.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,5 +90,8 @@ int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size)
utf8proc_map(data, len, &str, UTF8PROC_COMPOSE | UTF8PROC_STRIPMARK);
free(str);

utf8proc_map(data, len, &str, UTF8PROC_CHARBOUND | UTF8PROC_DECOMPOSE);
free(str);

return 0;
}
}
10 changes: 10 additions & 0 deletions utf8proc.c
Original file line number Diff line number Diff line change
Expand Up @@ -595,7 +595,17 @@ UTF8PROC_DLLEXPORT utf8proc_ssize_t utf8proc_decompose_custom(
utf8proc_int32_t uc1, uc2;
const utf8proc_property_t *property1, *property2;
uc1 = buffer[pos];
if (uc1 < 0) {
/* skip grapheme break */
pos++;
continue;
}
uc2 = buffer[pos+1];
if (uc2 < 0) {
/* cannot recombine; skip grapheme break */
pos+=2;
continue;
}
property1 = unsafe_get_property(uc1);
property2 = unsafe_get_property(uc2);
if (property1->combining_class > property2->combining_class &&
Expand Down
2 changes: 1 addition & 1 deletion utf8proc.h
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
/** The MINOR version number (increased when new functionality is added in a backwards-compatible manner). */
#define UTF8PROC_VERSION_MINOR 11
/** The PATCH version (increased for fixes that do not change the API). */
#define UTF8PROC_VERSION_PATCH 0
#define UTF8PROC_VERSION_PATCH 1
/** @} */

#include <stdlib.h>
Expand Down