Add some more casts (1/2)
[deliverable/binutils-gdb.git] / gdb / gdbserver / thread-db.c
index 3da636e59e4d4f2739657c6e83f4cf2e3ac822cd..ffe722dcdd4f0780273706eb82743f3eab4c99cf 100644 (file)
@@ -562,7 +562,7 @@ thread_db_load_search (void)
 
   gdb_assert (proc->priv->thread_db == NULL);
 
-  tdb = xcalloc (1, sizeof (*tdb));
+  tdb = XCNEW (struct thread_db);
   proc->priv->thread_db = tdb;
 
   tdb->td_ta_new_p = &td_ta_new;
@@ -607,7 +607,7 @@ try_thread_db_load_1 (void *handle)
 
   gdb_assert (proc->priv->thread_db == NULL);
 
-  tdb = xcalloc (1, sizeof (*tdb));
+  tdb = XCNEW (struct thread_db);
   proc->priv->thread_db = tdb;
 
   tdb->handle = handle;
@@ -749,7 +749,7 @@ try_thread_db_load_from_dir (const char *dir, size_t dir_len)
 
   if (dir_len + 1 + strlen (LIBTHREAD_DB_SO) + 1 > sizeof (path))
     {
-      char *cp = xmalloc (dir_len + 1);
+      char *cp = (char *) xmalloc (dir_len + 1);
 
       memcpy (cp, dir, dir_len);
       cp[dir_len] = '\0';
@@ -874,7 +874,7 @@ thread_db_init (int use_events)
 static int
 any_thread_of (struct inferior_list_entry *entry, void *args)
 {
-  int *pid_p = args;
+  int *pid_p = (int *) args;
 
   if (ptid_get_pid (entry->id) == *pid_p)
     return 1;
This page took 0.027303 seconds and 4 git commands to generate.