Skip to content

Commit a779aa7

Browse files
committed
Fix allocator use.
1 parent e9e717c commit a779aa7

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

include/simstr/sstring.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3257,7 +3257,7 @@ class decl_empty_bases lstring :
32573257
}
32583258
/*!
32593259
* @ru @brief Определить длину строки.
3260-
* Ищет символ 0 в буфере строки до его ёмкости, после чего устаналивает длину строки по найденному 0.
3260+
* Ищет символ 0 в буфере строки до его ёмкости, после чего устанавливает длину строки по найденному 0.
32613261
* @en @brief Determine the length of the string.
32623262
* Searches for the character 0 in the string buffer to its capacity, and then sets the length of the string to the found 0.
32633263
*/
@@ -3283,7 +3283,7 @@ class decl_empty_bases lstring :
32833283
if (is_alloced() && capacity_ > need_capacity) {
32843284
K* newData = size_ <= LocalCapacity ? local_ : alloc_place(need_capacity);
32853285
traits::copy(newData, data_, size_ + 1);
3286-
base_storable::allocator().deallocate(to_real_address(data_));
3286+
dealloc();
32873287
data_ = newData;
32883288

32893289
if (size_ > LocalCapacity) {

0 commit comments

Comments
 (0)