Fwd: XDG Base directory specification
bastian at kde.org
Wed Jun 4 14:56:02 EEST 2003
-----BEGIN PGP SIGNED MESSAGE-----
On Tuesday 03 June 2003 18:20, Jonathan Blandford wrote:
> Waldo Bastian <bastian at kde.org> writes:
> > An invalid directory would be mostly a "non-existing directory", no?
> Kind of. A directory in the environment can be invalid for two reasons.
> It can be a valid name of a problematic directory. For example, the
> directory (or its parents) could not exist, there could be permission
> problems, and temporary non-working of file systems.
> Additionally, the environment could be empty, have a relative directory,
> or be invalid UTF-8, where we can't possibly get a directory. Perhaps
> the spec should clarify between the two, and say something like:
> "If the directory appears to be a valid directory name but isn't
> available, the program should make a good-faith effort to access it
> during the lifetime of the program. It should let the user know about
> any problems that it runs into while trying to save. If the directory
> name itself isn't valid, then the default environment is used."
I don't think the issue of invalid directory names should be addressed
separately, I don't think it is fundamentally different from a directory that
is unaccessible e.g. due to lack of permissions.
It might be useful to include the following though:
When attempting to write a file, iff the destination directory is non-existant
an attempt should be made to create it with permission 0700. The application
should be prepared to handle the case where the file could not be written,
either because the directory was non-existant and could not be created, or
for any other reason. In such case it may chose to present an error message
to the user.
When attempting to read a file, if for any reason a file in a certain
directory is unaccessible, e.g. because the directory is non-existant, the
file is non-existant or the user is not authorized to open the file, then the
processing of such file should be skipped. If due to this a required file
could not be found at all, the application may chose to present an error
message to the user.
bastian at kde.org -=|[ SuSE, The Linux Desktop Experts ]|=- bastian at suse.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org
-----END PGP SIGNATURE-----
More information about the xdg