CodeEditApp / CodeEditApp/CodeEdit

🐞 Possible memory leak in CurrentUser struct

Đang mở
#2,133 1 bình luận 0 reaction 0 người được giao Xem trên GitHub
bug
Ngôn ngữ chính
Swift
Star
23k
Fork
1.2k
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

### Description

In `CurrentUser.getCurrentUser()`, an `UnsafeMutablePointer` is allocated but never explicitly freed. When I added a `deallocate()` call in a defer block, the process crashed saying the pointer was freed but never allocated. I am uncertain if there is a memory leak here.

### To Reproduce

1. Open a workspace, thus creating a terminal, which calls `CurrentUser.getCurrentUser()`.

### Expected Behavior

No memory leak, but, again, I am uncertain if there is actually a leak here.

### Version Information

CodeEdit: 0.3.6-dev (37)
macOS: 15.6.1
Xcode: 26.0

### Additional Context

_No response_

### Screenshots

_No response_

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.