[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-parted] Re: parted 1.3.x errata

From: Damien Genet
Subject: Re: [Bug-parted] Re: parted 1.3.x errata
Date: Thu, 28 Sep 2000 16:35:46 +0200


> Hmmm.  I think you should add the partition immediately, and keep
> on changing the added partition, as the user changes things in the
> dialog box.
> If the user cancels, then reread the disk.

The problem is, that changes are not directly written to disk,
I don't work as in Parted text-tool,
PedDisk*'s are closed only on exit, and they are sync
whith the physical disk, only when you choose the write option,
or when you do FS operations likes creating (it asks you before
sync). So you can test different partitioning without destroying the
This, will also allow to undo last operations (stuff for latter, when
Gtk-Parted will still be usable), with maybe an operations list
So I musn't sync after each ops, and I will also need to keep all
PedPartition* until sync to allow undo.

> memcpy wouldn't work.  There is arbitary data in part->disk_specific,
> which could contain pointers, etc.

We could also memcpy disk->disk_specific and then
link the copy to the copy of the partition, but for this we
must know the size of it.
So, this should be internal,  adding to PedDiskOps :
PedPartition * (*partition_duplicate) (
        [PedDisk *disk,]  /* I'm not sure this arg is usefull */
        PedPartition *part);
The other possibility is to add a function to PedDiskOps
that's returns the size needed for part->disk_specific, or allocate it,
but I don't like this Idea : this is really less "clean".

> Anyway, I think there are lots of ways we could try to solve this
> problem, so it'd be good to talk about it.  I think IRC is better for
> this.
> (BTW: anyone can come along!)

This is a good Idea, but this should rather be on week-end, because
whit my ISDN connection, I must optimise my phone bill, - but ADSL,
may come at the end of next year, in my 'lost' village :), when they
already have it at 15Km :( -, whe should also find the hour, because of
the time difference.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]