Topic "ini file attributes problems"

Author Message
jsimlo

Guest


Hi,

In version 4.0.3: Settting the winscp403.ini file as read-only issues a message box about "writting" error upon exit. Setting the file as hidden works fine.

In version 4.0.5: Settting the winscp403.ini file as read-only and/or hidden issues several message boxes about "creating" error. Twice upon startup, once upon exit.

Setting the file as hidden should not prevent the write operation. Hidden configs are useful for portable users to hide "unimportant" files on usb. In terms of WinAPI, this can be done by specifying hidden attribute in the call to CreateFile. As it is described in the remarks section of the SDK, in order to preserve file attributes, you need to do something like this:

dwAttribs = GetFileAttributes (szFileName);
CreateFile (szFileName, ..., dwAttribs, ...);

Also, I would like to request the error messages upon read-only to be removed (at least by an option). Especially, when no change is made. Setting a config file as read-only does not earn an error. Disk full earns an error though. Furthermore, running WinSCP from a read-only network drive with ini file present always results in three unwanted errors, which gets annoying.. :))

Take care,
jsimlo
Advertisements
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
jsimlo wrote:
Setting the file as hidden should not prevent the write operation.

Fixed already. Thanks.

Quote:
Also, I would like to request the error messages upon read-only to be removed (at least by an option). Especially, when no change is made.

When no change is made (rare though), file won't be saved anymore.
_________________
Martin Prikryl
jsimlo

Guest


prikryl wrote:
Quote:
Also, I would like to request the error messages upon read-only to be removed (at least by an option). Especially, when no change is made.

When no change is made (rare though), file won't be saved anymore.


Rare? Well, there's a new request then.. :)) Most of the programs I know do not report errors from settings saving (including Firefox, Internet Explorer, Total Commander, WinAmp, BSPlayer, Miranda, Notepad, Photoshop, etc.), therefore, I think WinSCP deviates from what could be called an intuitive behavior.

Note that some of the programs mentioned above actually can report such errors when the saving is manually invoked by the user, or when the file is writable, but the disk is full. But they all silently fail upon exit when the file is read only (either because of read-only flag, or because of a read only device: cd-rom, network drive, etc.)

My suggestion is either to siletny fail upon background saving errors (when the user did not invoked any saving himself), which seems to be the best solution for both sides; or at least give us an option to check, to skip any settings errors. As you probably already noticed from many messages from this forum, repeated errors are the most annoying thing that an application can generate.. :))

With kind regards,
jsimlo
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
OK, I can supress error meassage upon implicit saving to read-only file.
_________________
Martin Prikryl
jsimlo

Guest


prikryl wrote:
OK, I can supress error meassage upon implicit saving to read-only file.

Many thanks.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
prikryl wrote:
OK, I can supress error meassage upon implicit saving to read-only file.

This feature has been implemented already. It will be included into the next release.
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License