>>>>> "Christian" == Christian Biesinger via gdb-patches <gdb-patches@sourceware.org> writes:
>> I wonder if using a unique_xmalloc_ptr would be better.>> I suppose it doesn't matter hugely, but it would eliminate some of these>> double allocations.
Christian> Do you mean for the return type of relocate_path and
Christian> relocate_gdb_directory? Hm.. I can change it if you want, but I'd
Christian> rather not -- not all codepaths go through an xmalloc (when
Christian> relocatable=false, or relocate_path returns null in
Christian> relocate_gdb_directory). So that would add some xstrdup calls that
Christian> would not otherwise be necessary.
Yeah. What you did sounds fine.
Tom