Ethereal-dev: Re: [Ethereal-dev] Save As over existing file fails?

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Ulf Lamping <ulf.lamping@xxxxxx>
Date: Tue, 17 Feb 2004 18:57:25 +0100
Lars Ruoff wrote:

Shouldn't "Save As" be allowed to save over an existing file?
It throws the following error:
"Can't save over current capture file: [etherXXX...]",
where etherXXX is the name of a temporary file, not the file i actually want
to save over.

(built from last nightly CVS, Windows2000, GLib2.2.1, GTK+1.3)
best regards,
Lars Ruoff

Fixed the bug about the dialog text.


In an ideal world, it would ask the user when detecting this: "Do you want to overwrite existing file?" YES/NO/CANCEL or such. The problem is: the current save mechanism (in file.c) is very monolithic. Theres no easy way to achieve the behaviour I described.

So, I wouldn't overwrite an existing file, without asking the user first about this. As this isn't easily possible, it won't be a good idea to simply
overwrite without any confirmation, as unintended data loss might occur.


The file.c mechanisms should be redesigned IHMO, but don't expect changes too soon on this.

Regards, ULFL