2009-06-18 Vladimir Serbinenko <phcoder@gmail.com>

Fix warnings

	* fs/ntfscomp.c (decomp_get16): initialize c1 and c2
	(decomp_block): initialize ch
	use grub_memcpy instead of memcpy
This commit is contained in:
phcoder 2009-06-18 13:51:06 +00:00
parent d363867871
commit 09b3490b9d
2 changed files with 11 additions and 3 deletions

View File

@ -1,3 +1,11 @@
2009-06-18 Vladimir Serbinenko <phcoder@gmail.com>
Fix warnings
* fs/ntfscomp.c (decomp_get16): initialize c1 and c2
(decomp_block): initialize ch
use grub_memcpy instead of memcpy
2009-06-17 Pavel Roskin <proski@gnu.org>
* include/grub/i386/coreboot/console.h: Don't use the i386-pc

View File

@ -57,7 +57,7 @@ decomp_getch (struct grub_ntfs_comp *cc, unsigned char *res)
static grub_err_t
decomp_get16 (struct grub_ntfs_comp *cc, grub_uint16_t * res)
{
unsigned char c1, c2;
unsigned char c1 = 0, c2 = 0;
if ((decomp_getch (cc, &c1)) || (decomp_getch (cc, &c2)))
return grub_errno;
@ -134,7 +134,7 @@ decomp_block (struct grub_ntfs_comp *cc, char *dest)
}
else
{
unsigned char ch;
unsigned char ch = 0;
if (decomp_getch (cc, &ch))
return grub_errno;
@ -163,7 +163,7 @@ decomp_block (struct grub_ntfs_comp *cc, char *dest)
n = cnt;
if ((dest) && (n))
{
memcpy (dest, &cc->cbuf[cc->cbuf_ofs], n);
grub_memcpy (dest, &cc->cbuf[cc->cbuf_ofs], n);
dest += n;
}
cnt -= n;