lkml.org 
[lkml]   [2002]   [Aug]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: 2.5.28 and partitions
From
On Thu, Aug 01, 2002 at 05:24:37PM -0400, Albert D. Cahalan wrote:
> Alexander Viro writes:
> > [...]
> >> On Wed, 31 Jul 2002, Alexander Viro wrote:
>
> >>> What the bleedin' hell is wrong with <name> <start> <len>\n
> >>> - all in ASCII? Terminated by \0. No need for flags, no need
> >>> for endianness crap, no need to worry about field becoming too
> >>> narrow...
>
> There's just that little overflow problem to worry about,

Ummm:

-- stuff ASCII digits into u64 (or u32, or whatever)
-- if (still more digits)
-- printk("partition too big to mount!\n")
-- return error
How hard is that?

> trailing garbage,

Don't write garbage into your partition table.

> encouragement of assumptions about the maximum size...
> is that a %d or a %llu or what?

See above. Use leading '-' for negative numbers. ASCII has no
2's complement ambiguity issues.

miket
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:27    [W:0.208 / U:0.188 seconds]
©2003-2014 Jasper Spaans. Advertise on this site