This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH 5/6] Mention that create_child takes ownership of the allocated name


gdb/ChangeLog:

	* varobj.c (create_child): Modify comment.
---
 gdb/varobj.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/gdb/varobj.c b/gdb/varobj.c
index 0daef91..d3fa1ba 100644
--- a/gdb/varobj.c
+++ b/gdb/varobj.c
@@ -2043,7 +2043,9 @@ uninstall_variable (struct varobj *var)
 
 }
 
-/* Create and install a child of the parent of the given name.  */
+/* Create and install a child of the parent of the given name.
+
+   The created VAROBJ takes ownership of the allocated NAME.  */
 static struct varobj *
 create_child (struct varobj *parent, int index, char *name)
 {
-- 
2.1.4


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]