[PATCH 4/4] score: Free old name in _Objects_Set_name()
Sebastian Huber
sebastian.huber at embedded-brains.de
Tue Nov 24 12:52:24 UTC 2020
This is the behaviour document in the RTEMS Classic API Guide.
---
cpukit/score/src/objectsetname.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/cpukit/score/src/objectsetname.c b/cpukit/score/src/objectsetname.c
index 4d85332711..4cb19bd360 100644
--- a/cpukit/score/src/objectsetname.c
+++ b/cpukit/score/src/objectsetname.c
@@ -40,6 +40,7 @@ Status_Control _Objects_Set_name(
return STATUS_NO_MEMORY;
}
+ _Workspace_Free( the_object->name.name_p );
the_object->name.name_p = dup;
} else {
char c[ 4 ];
--
2.26.2
More information about the devel
mailing list