asprintf and snprintf support

This commit is contained in:
Vladimir 'phcoder' Serbinenko 2009-12-29 10:04:06 +01:00
parent c181849b95
commit 8b442f3f4c
60 changed files with 396 additions and 345 deletions

View file

@ -90,10 +90,7 @@ grub_machine_set_prefix (void)
}
prefix = grub_ieee1275_encode_devname (bootpath);
path = grub_malloc (grub_strlen (grub_prefix)
+ grub_strlen (prefix)
+ 2);
grub_sprintf(path, "%s%s", prefix, grub_prefix);
path = grub_asprintf("%s%s", prefix, grub_prefix);
grub_strcpy (grub_prefix, path);