Date: Wed, 10 Oct 2001 13:47:57 -0700 (PDT) From: John Baldwin <jhb@FreeBSD.org> To: The Anarcat <anarcat@anarcat.dyndns.org> Cc: freebsd-libh@freebsd.org, alex@big.endian.de, Jordan Hubbard <jkh@freebsd.org> Subject: Re: adding Disk::freespace to lib[h]disk Message-ID: <XFMail.011010134757.jhb@FreeBSD.org> In-Reply-To: <20011010160737.C1233@shall.anarcat.dyndns.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On 10-Oct-01 The Anarcat wrote: > Chocolate chip cookies, eh? > > What brand? :) > > Seriously, I don't think I could seriously take this challenge, as > libdisk is too messy to start from and I do not have enough knowledge of > these internals. I guess I could try to re-implement functions such as > Int_Open_Disk() in a separate (the low-level) library. It shouldn't be > too difficult, assuming the current *implementation* is correct (it's > the API that screwed in libdisk case, right?). > > I'll look at the libwhisk John mentionned, though. The API does need major work. Please do look at libwhisk rather than reinvent it. If you do choose to write your own, I would do it in C++. :) With a base class for a piece of a disk that disklabel partitions and MBR slices are built from (along with some kind of abstraction for a piece container that contains the list of containers, thus, a MBR slice would have in it a disklabel container that contained disklabel partitions), etc. Most of the work would be in the container classes. Hmm, actually, since the containers each have a fixed number of containee's, I would just use an abstraction for the containers that allows for nesting, and throw out the notion of a object for each piece, etc. > A. > > On Wed Oct 10, 2001 at 12:57:07PM -0700, Jordan Hubbard wrote: >> You're making perfect sense. We've long known that libdisk(3) needed >> to be taken out in back of the barn and shot through the head, but there's >> just been nobody around to do it so we're still stuck with that evil piece >> of.... code. The person who re-implements libdisk correctly will get >> a whole box of chocolate chip cookies in the mail from me. :) >> >> - Jordan -- John Baldwin <jhb@FreeBSD.org> -- http://www.FreeBSD.org/~jhb/ PGP Key: http://www.baldwin.cx/~john/pgpkey.asc "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-libh" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?XFMail.011010134757.jhb>