mirror of
https://git.savannah.gnu.org/git/grub.git
synced 2026-10-26 00:59:55 +00:00
2004-07-12 Marco Gerards <metgerards@student.han.nl>
* normal/arg.c (grub_arg_parse): Correct error handling after reallocating the argumentlist (check if `argl' is not null instead of checking if `args' is not null). * kern/mm.c (grub_realloc): Return the same pointer when using the same region, instead of returning the header address.
This commit is contained in:
1 parent
e15199cb7b
commit
5a9e354626
3 files changed
+10
-2
No files matched your search
@@ -1,3 +1,11 @@
|
|||||||
|
2004-07-12 Marco Gerards <metgerards@student.han.nl>
|
||||||
|
|
||||||
|
* normal/arg.c (grub_arg_parse): Correct error handling after
|
||||||
|
reallocating the argumentlist (check if `argl' is not null instead
|
||||||
|
of checking if `args' is not null).
|
||||||
|
* kern/mm.c (grub_realloc): Return the same pointer when using the
|
||||||
|
same region, instead of returning the header address.
|
||||||
|
|
||||||
2004-07-11 Marco Gerards <metgerards@student.han.nl>
|
2004-07-11 Marco Gerards <metgerards@student.han.nl>
|
||||||
|
|
||||||
* disk/powerpc/ieee1275/partition.c (grub_partition_iterate): Skip
|
* disk/powerpc/ieee1275/partition.c (grub_partition_iterate): Skip
|
||||||
|
|||||||
@@ -335,7 +335,7 @@ grub_realloc (void *ptr, grub_size_t size)
|
|||||||
get_header_from_pointer (ptr, &p, &r);
|
get_header_from_pointer (ptr, &p, &r);
|
||||||
|
|
||||||
if (p->size >= n)
|
if (p->size >= n)
|
||||||
return p;
|
return ptr;
|
||||||
|
|
||||||
q = grub_malloc (size);
|
q = grub_malloc (size);
|
||||||
if (! q)
|
if (! q)
|
||||||
|
|||||||
+1
-1
@@ -189,7 +189,7 @@ grub_arg_parse (grub_command_t cmd, int argc, char **argv,
|
|||||||
grub_err_t add_arg (char *s)
|
grub_err_t add_arg (char *s)
|
||||||
{
|
{
|
||||||
argl = grub_realloc (argl, (++num) * sizeof (char *));
|
argl = grub_realloc (argl, (++num) * sizeof (char *));
|
||||||
if (! args)
|
if (! argl)
|
||||||
return grub_errno;
|
return grub_errno;
|
||||||
argl[num - 1] = s;
|
argl[num - 1] = s;
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
Reference in new issue
Block a user