* solist.h (target_so_ops.find_and_open_solib): Clarify usage of
authorDoug Evans <dje@google.com>
Tue, 16 Jul 2013 20:43:48 +0000 (20:43 +0000)
committerDoug Evans <dje@google.com>
Tue, 16 Jul 2013 20:43:48 +0000 (20:43 +0000)
temp_pathname argument.
* nto-tdep.c (nto_find_and_open_solib): Fix setting of temp_pathname
when opening the file fails.

gdb/ChangeLog
gdb/nto-tdep.c
gdb/solist.h

index 9bc9a33cf034db96958f47b9302d10b516dd46e4..67ce94ba204574becc4ff644467f6f5b826e8683 100644 (file)
@@ -1,5 +1,10 @@
 2013-07-16  Doug Evans  <dje@google.com>
 
+       * solist.h (target_so_ops.find_and_open_solib): Clarify usage of
+       temp_pathname argument.
+       * nto-tdep.c (nto_find_and_open_solib): Fix setting of temp_pathname
+       when opening the file fails.
+
        * target.h (struct target_section): Delete member bfd.
        All users updated to use the_bfd_section->owner instead.
        * exec.c (add_to_section_table): Assert bfd is expected value.
index b1a431ccaf15730670325469286e8d5a413aec52..3ed48a95f8749bd344b668de3554d3e7f03f596b 100644 (file)
@@ -138,7 +138,7 @@ nto_find_and_open_solib (char *solib, unsigned o_flags, char **temp_pathname)
          if (ret >= 0)
            *temp_pathname = gdb_realpath (arch_path);
          else
-           **temp_pathname = '\0';
+           *temp_pathname = NULL;
        }
     }
   return ret;
index 244484a6dcd4a470d3af51a436b631f6bc0fe6bf..a78e3ea5f87cad7e3689d3f05708f1019804a238 100644 (file)
@@ -129,8 +129,10 @@ struct target_so_ops
     /* Find and open shared library binary file.  */
     bfd *(*bfd_open) (char *pathname);
 
-    /* Extra hook for finding and opening a solib.
-       Convenience function for remote debuggers finding host libs.  */
+    /* Optional extra hook for finding and opening a solib.
+       If TEMP_PATHNAME is non-NULL: If the file is successfully opened a
+       pointer to a malloc'd and realpath'd copy of SONAME is stored there,
+       otherwise NULL is stored there.  */
     int (*find_and_open_solib) (char *soname,
         unsigned o_flags, char **temp_pathname);
 
This page took 0.028034 seconds and 4 git commands to generate.