[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Small Bug in grub-core/partmap/amiga.c
From: |
Vladimir 'φ-coder/phcoder' Serbinenko |
Subject: |
Re: Small Bug in grub-core/partmap/amiga.c |
Date: |
Fri, 31 Dec 2010 15:08:12 +0100 |
User-agent: |
Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.16) Gecko/20101226 Icedove/3.0.11 |
On 12/30/2010 07:29 AM, address@hidden wrote:
> Alas, AmigaOS has mostly passed beyond the veil, but one can still find
> small bugs sometimes:
>
BTW, Amiga partmap and filesystems support in GRUB is for AROS, not Amiga.
> === modified file 'grub-core/partmap/amiga.c'
> --- grub-core/partmap/amiga.c 2010-03-26 14:44:13 +0000
> +++ grub-core/partmap/amiga.c 2010-12-30 06:25:26 +0000
> @@ -87,7 +87,7 @@
> if (grub_disk_read (disk, pos, 0, sizeof (rdsk), &rdsk))
> return grub_errno;
>
> - if (grub_strcmp ((char *) rdsk.magic, "RDSK") == 0)
> + if (grub_strncmp ((char *) rdsk.magic, "RDSK", sizeof(rdsk.magic)) ==
> 0)
> {
> /* Found the first PART block. */
> next = grub_be_to_cpu32 (rdsk.partitionlst);
>
>
> I both like and dislike using strcmp() for this purpose. I kind of like
> keeping it as a string, but strcmp()... Anyway, minimal solution.
>
>
>
--
Regards
Vladimir 'φ-coder/phcoder' Serbinenko
signature.asc
Description: OpenPGP digital signature