[PR #6598] [MERGED] bugfix: fix possible memory leak in fs_home.c #6089

Closed
opened 2026-05-05 10:50:31 -06:00 by gitea-mirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/netblue30/firejail/pull/6598
Author: @peter15914
Created: 1/3/2025
Status: Merged
Merged: 1/4/2025
Merged by: @kmk3

Base: masterHead: fix_memory_leak


📝 Commits (1)

  • b88bc52 bugfix: fix possible memory leak in fs_home.c

📊 Changes

1 file changed (+1 additions, -0 deletions)

View changed files

📝 src/firejail/fs_home.c (+1 -0)

📄 Description

The pointer returned by asprintf() should be passed to free() to release the allocated storage when it is no longer needed.
There was one exit point without previous freeing src.

Relates to:


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/netblue30/firejail/pull/6598 **Author:** [@peter15914](https://github.com/peter15914) **Created:** 1/3/2025 **Status:** ✅ Merged **Merged:** 1/4/2025 **Merged by:** [@kmk3](https://github.com/kmk3) **Base:** `master` ← **Head:** `fix_memory_leak` --- ### 📝 Commits (1) - [`b88bc52`](https://github.com/netblue30/firejail/commit/b88bc52aa03fab76d1e1fba83be10b72b1e0302a) bugfix: fix possible memory leak in fs_home.c ### 📊 Changes **1 file changed** (+1 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `src/firejail/fs_home.c` (+1 -0) </details> ### 📄 Description The pointer returned by ```asprintf()``` should be passed to free() to release the allocated storage when it is no longer needed. There was one exit point without previous freeing ```src```. Relates to: * #6367 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
gitea-mirror 2026-05-05 10:50:31 -06:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/firejail#6089
No description provided.