When I converted this code over to user dynamically allocated
strings, I inserted a bug by passing the address of the string
pointer instead of the pointer itself.

Committed.

2009-05-04  David S. Miller  <da...@davemloft.net>

        * kern/ieee1275/openfw.c (grub_children_iterate): Fix string
        pointer args to grub_ieee1275_get_property().

diff --git a/kern/ieee1275/openfw.c b/kern/ieee1275/openfw.c
index 7d65023..31296b1 100644
--- a/kern/ieee1275/openfw.c
+++ b/kern/ieee1275/openfw.c
@@ -78,7 +78,7 @@ grub_children_iterate (char *devpath,
       struct grub_ieee1275_devalias alias;
       grub_ssize_t actual;
 
-      if (grub_ieee1275_get_property (child, "device_type", &childtype,
+      if (grub_ieee1275_get_property (child, "device_type", childtype,
                                      sizeof childtype, &actual))
        continue;
 
@@ -86,7 +86,7 @@ grub_children_iterate (char *devpath,
                                         &actual))
        continue;
 
-      if (grub_ieee1275_get_property (child, "name", &childname,
+      if (grub_ieee1275_get_property (child, "name", childname,
                                      sizeof childname, &actual))
        continue;
 


_______________________________________________
Grub-devel mailing list
Grub-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/grub-devel

Reply via email to