Change grub_memmove to use void *
This commit is contained in:
parent
0651145eca
commit
c7b6b37e1d
3 changed files with 10 additions and 5 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2000-05-29 Chip Salzenberg <chip@valinux.com>
|
||||||
|
|
||||||
|
* stage2/shared.h (grub_memmove): Prototype to use void *.
|
||||||
|
* stage2/char_io.c (grub_memmove): Define likewise.
|
||||||
|
|
||||||
2000-05-30 Gordon Matzigkeit <gord@fig.org>
|
2000-05-30 Gordon Matzigkeit <gord@fig.org>
|
||||||
|
|
||||||
* docs/user-ref.texi (Stage2 errors): Update error messages.
|
* docs/user-ref.texi (Stage2 errors): Update error messages.
|
||||||
|
|
|
@ -846,8 +846,8 @@ memcheck (int addr, int len)
|
||||||
return ! errnum;
|
return ! errnum;
|
||||||
}
|
}
|
||||||
|
|
||||||
char *
|
void *
|
||||||
grub_memmove (char *to, const char *from, int len)
|
grub_memmove (void *to, const void *from, int len)
|
||||||
{
|
{
|
||||||
if (memcheck ((int) to, len))
|
if (memcheck ((int) to, len))
|
||||||
{
|
{
|
||||||
|
@ -873,8 +873,8 @@ grub_memmove (char *to, const char *from, int len)
|
||||||
"cld"
|
"cld"
|
||||||
: "=&c" (d0), "=&S" (d1), "=&D" (d2)
|
: "=&c" (d0), "=&S" (d1), "=&D" (d2)
|
||||||
: "0" (len),
|
: "0" (len),
|
||||||
"1" (len - 1 + from),
|
"1" (len - 1 + (const char *) from),
|
||||||
"2" (len - 1 + to)
|
"2" (len - 1 + (char *) to)
|
||||||
: "memory");
|
: "memory");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -698,7 +698,7 @@ int grub_sprintf (char *buffer, const char *format, ...);
|
||||||
int grub_tolower (int c);
|
int grub_tolower (int c);
|
||||||
int grub_isspace (int c);
|
int grub_isspace (int c);
|
||||||
int grub_strncat (char *s1, const char *s2, int n);
|
int grub_strncat (char *s1, const char *s2, int n);
|
||||||
char *grub_memmove (char *to, const char *from, int len);
|
void *grub_memmove (void *to, const void *from, int len);
|
||||||
void *grub_memset (void *start, int c, int len);
|
void *grub_memset (void *start, int c, int len);
|
||||||
int grub_strncat (char *s1, const char *s2, int n);
|
int grub_strncat (char *s1, const char *s2, int n);
|
||||||
char *grub_strstr (const char *s1, const char *s2);
|
char *grub_strstr (const char *s1, const char *s2);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue