Remove strcat_to_buf
authorTom Tromey <tom@tromey.com>
Mon, 2 Sep 2019 15:07:02 +0000 (09:07 -0600)
committerTom Tromey <tom@tromey.com>
Fri, 20 Sep 2019 19:49:11 +0000 (13:49 -0600)
An earlier patch in the series removed the last call to strcat_to_buf,
so this patch removes the function entirely.

gdb/ChangeLog
2019-09-20  Tom Tromey  <tom@tromey.com>

* tui/tui.h (strcat_to_buf): Don't declare.
* tui/tui.c (strcat_to_buf): Remove.

gdb/ChangeLog
gdb/tui/tui.c
gdb/tui/tui.h

index 3b2fdd2056584e87f1caa2a347dc03dd8e415dd4..ba434dd30033413e1da88e85f14ef21cc815a4cb 100644 (file)
@@ -1,3 +1,8 @@
+2019-09-20  Tom Tromey  <tom@tromey.com>
+
+       * tui/tui.h (strcat_to_buf): Don't declare.
+       * tui/tui.c (strcat_to_buf): Remove.
+
 2019-09-20  Tom Tromey  <tom@tromey.com>
 
        * tui/tui-source.h (struct tui_source_window) <m_fullname>: Rename
index 966304f34080197740bce2acc83c81e678e92cf6..30bf54887941585adf806192b5eb4c9fd5100a9c 100644 (file)
@@ -570,19 +570,6 @@ tui_disable_command (const char *args, int from_tty)
   tui_disable ();
 }
 
-void
-strcat_to_buf (char *buf, int buflen, 
-              const char *item_to_add)
-{
-  if (item_to_add != NULL && buf != NULL)
-    {
-      if ((strlen (buf) + strlen (item_to_add)) <= buflen)
-       strcat (buf, item_to_add);
-      else
-       strncat (buf, item_to_add, (buflen - strlen (buf)));
-    }
-}
-
 #if 0
 /* Solaris <sys/termios.h> defines CTRL.  */
 #ifndef CTRL
index 25ae0c5e471fe1abd4d8ca7d9596d856f0de32fb..baf4a813b6076a41270605e1313968e050c385fe 100644 (file)
@@ -24,8 +24,6 @@
 
 struct ui_file;
 
-extern void strcat_to_buf (char *, int, const char *);
-
 /* Types of error returns.  */
 enum tui_status
 {
This page took 0.030393 seconds and 4 git commands to generate.