Election-Tech-Initiative / Election-Tech-Initiative/electionguard-core2

🐞 Contest and Selection Can Leak Memory

Open
#29 0 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
C#
Stars
14
Forks
12
PR merge metrics
No merged PRs in 30d

Description

### Is there an existing issue for this?

- [ ] I have searched the existing issues

### Current Behavior

If you create a PlaintextBallotSelection or PlaintextBallotContest in C# and immediately dispose of them, the underlying C++ won't get disposed and you'll have a memory leak. The underlying C++ objects currently only get disposed when you add them to a ballot and then dispose of the ballot.

### Expected Behavior

_No response_

### Steps To Reproduce

_No response_

### Environment

```markdown
- OS:
```

### Anything else?

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.