switch (child)
     {
     case -1:
-      warning (_("test bts: cannot fork: %s."), strerror (errno));
+      warning (_("test bts: cannot fork: %s."), safe_strerror (errno));
       return 0;
 
     case 0:
       if (status != 0)
        {
          warning (_("test bts: cannot PTRACE_TRACEME: %s."),
-                  strerror (errno));
+                  safe_strerror (errno));
          _exit (1);
        }
 
       if (status != 0)
        {
          warning (_("test bts: cannot raise SIGTRAP: %s."),
-                  strerror (errno));
+                  safe_strerror (errno));
          _exit (1);
        }
 
       if (pid != child)
        {
          warning (_("test bts: bad pid %ld, error: %s."),
-                  (long) pid, strerror (errno));
+                  (long) pid, safe_strerror (errno));
          return 0;
        }
 
       if (pid != child)
        {
          warning (_("test bts: bad pid %ld, error: %s."),
-                  (long) pid, strerror (errno));
+                  (long) pid, safe_strerror (errno));
          if (!WIFSIGNALED (status))
            warning (_("test bts: expected killed. status: %d."),
                     status);
   switch (child)
     {
     case -1:
-      warning (_("test pt: cannot fork: %s."), strerror (errno));
+      warning (_("test pt: cannot fork: %s."), safe_strerror (errno));
       return 0;
 
     case 0:
       if (status != 0)
        {
          warning (_("test pt: cannot PTRACE_TRACEME: %s."),
-                  strerror (errno));
+                  safe_strerror (errno));
          _exit (1);
        }
 
       if (status != 0)
        {
          warning (_("test pt: cannot raise SIGTRAP: %s."),
-                  strerror (errno));
+                  safe_strerror (errno));
          _exit (1);
        }
 
       if (pid != child)
        {
          warning (_("test pt: bad pid %ld, error: %s."),
-                  (long) pid, strerror (errno));
+                  (long) pid, safe_strerror (errno));
          return 0;
        }
 
       if (pid != child)
        {
          warning (_("test pt: bad pid %ld, error: %s."),
-                  (long) pid, strerror (errno));
+                  (long) pid, safe_strerror (errno));
          if (!WIFSIGNALED (status))
            warning (_("test pt: expected killed. status: %d."),
                     status);