[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: svn commit: rev 1563 - trunk/subversion/include trunk/subversion/libsvn_subr trunk/subversion/clients/cmdline trunk/subversion/libsvn_ra_dav

From: Hontvari Jozsef <hontvari_at_solware.com>
Date: 2002-03-22 12:56:41 CET

From: "Geisser, Oliver" <O.Geisser@CEYONIQ.COM>
> > The whole process:
> >
> > 1. First look for the APPDATA environment variable as it is
> > already in the
> > code sample. That will only exists on Windows 2000 and upper.
> > 2. If APPDATA is not set, then look for the USERPROFILE environment
> > variable. That exists from Windows NT 4. If found then use
> > the directory
> > %USERPROFILE%\Application Data. This will correspond to
> > APPDATA. If there is
> > no "Application Data" subdirectory then create it.
>
> Please do not make the same mistake like many other programms and hardcode
> Windows special folder names. The name "Application Data" is only valid
> for the english/US version. For example in germany it's called
> "Anwendungsdaten"

Well, using the Microsoft recommended SHGetFolderPath would be most correct
solution. But that requires a few lines of very Windows specific code
(dynamic binding is necessary to check the existence of the dll containing
that function). I wonder what the subversion architects are thinking about
this (?). The other problem is that SHGetFolderPath cannot help on Windows
NT 4 machine without service pack 5 or 6 anyway.

Maybe we should forget step 2, using USERPROFILE\Application Data as backup.
That is the easiest, after all :-) If no APPDATA then use the directory of
the executable.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Mar 22 14:05:16 2002

This is an archived mail posted to the Subversion Dev mailing list.