]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - gdb/skip.c
gdb/gdbsupport: make xstrprintf and xstrvprintf return a unique_ptr
[thirdparty/binutils-gdb.git] / gdb / skip.c
index 4d24088f2474db19d39e8663473b894258619d8a..0498becbdf1a74af7cbaa4140329bd3b5873c13f 100644 (file)
@@ -650,7 +650,7 @@ complete_skip_number (cmd_list_element *cmd,
 
   for (const skiplist_entry &entry : skiplist_entries)
     {
-      gdb::unique_xmalloc_ptr<char> name (xstrprintf ("%d", entry.number ()));
+      gdb::unique_xmalloc_ptr<char> name = xstrprintf ("%d", entry.number ());
       if (strncmp (word, name.get (), word_len) == 0)
        completer.add_completion (std::move (name));
     }