4paradigm / 4paradigm/OpenMLDB
ut: alloc-dealloc-mismatch (operator new [] vs free) in api_server_test
- 主要语言
- C++
- 星标
- 1.7k
- 派生
- 331
- 平均合并
- 12 天 12 小时
- 30 天内合并 PR
- 1
描述
Ref #358
```
==7595==ERROR: AddressSanitizer: alloc-dealloc-mismatch (operator new [] vs free) on 0x60600024df40
```
https://github.com/4paradigm/OpenMLDB/blob/326295840f6c2932c2d47937f8cf0ddf6c238664/hybridse/include/base/fe_slice.h#L104
is new [], we should use delete [], not free.
贡献指南
调研方向
The issue points to a specific line in hybridse/include/base/fe_slice.h where memory allocated with new[] is incorrectly freed with free. Start by examining that file around line 104 to understand the context. Look for the corresponding deallocation call and replace free with delete[]. Run the api_server_test with address sanitizer to verify the fix resolves the alloc-dealloc-mismatch error.
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- cpp
- 领域
- backend
- Issue 类型
- 缺陷
- 难度
- 1/5
- 预计耗时
- 1 小时以内
- 活跃度
- 停滞
- 描述清晰度
- 描述清楚
- 新手友好度
- 70/100