Gabe Black has submitted this change. (
https://gem5-review.googlesource.com/c/public/gem5/+/69557?usp=email )
Change subject: util: Add a missing free() to m5term.
......................................................................
util: Add a missing free() to m5term.
The "cwd" string is used to store the previous working directory, if
m5term needs to change it to maximize the space it has to create a
unix domain socket using a relative path. That string was not being
freed, which is a small memory leak. This change frees that memory.
Change-Id: I1ad901e7c59614dd938165cae91c3f666d86e872
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/69557
Maintainer: Gabe Black <[email protected]>
Tested-by: kokoro <[email protected]>
Reviewed-by: Jason Lowe-Power <[email protected]>
---
M util/term/term.c
1 file changed, 1 insertion(+), 0 deletions(-)
Approvals:
Jason Lowe-Power: Looks good to me, approved
Gabe Black: Looks good to me, approved
kokoro: Regressions pass
diff --git a/util/term/term.c b/util/term/term.c
index cf3fdda..b1624b2 100644
--- a/util/term/term.c
+++ b/util/term/term.c
@@ -235,6 +235,7 @@
perror("chdir back failed:");
exit(1);
}
+ free(cwd);
}
// Return the FD of our new connection.
--
To view, visit
https://gem5-review.googlesource.com/c/public/gem5/+/69557?usp=email
To unsubscribe, or for help writing mail filters, visit
https://gem5-review.googlesource.com/settings
Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: I1ad901e7c59614dd938165cae91c3f666d86e872
Gerrit-Change-Number: 69557
Gerrit-PatchSet: 2
Gerrit-Owner: Gabe Black <[email protected]>
Gerrit-Reviewer: Gabe Black <[email protected]>
Gerrit-Reviewer: Gabe Black <[email protected]>
Gerrit-Reviewer: Jason Lowe-Power <[email protected]>
Gerrit-Reviewer: Jui-min Lee <[email protected]>
Gerrit-Reviewer: Yu-hsin Wang <[email protected]>
Gerrit-Reviewer: kokoro <[email protected]>
Gerrit-MessageType: merged
_______________________________________________
gem5-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]