[Development] glib's and Qt's RuntimeLocation [OS X]

René J. V. Bertin rjvbertin at gmail.com
Wed Nov 25 21:24:10 CET 2015


Petroules Jake wrote:

[snipped]
> The only open question is what `macLocation` domain should be returned by
> QSP::TempLocation: kUserDomain, kSystemDomain or kOnAppropriateDisk . Maybe
> Jake Petroules already addressed that question?
> 
> In 5.7 QStandardPaths just uses QDir::tempPath(); there are no more calls to
> the Carbon File Manager.

If 5.7 still uses ObjC++ for qstandardpaths_mac, you could use 
NSTemporaryDirectory() for QSP::TempLocation, and let QDir::tempPath() use that, 
instead of the other way round. That would remove Thiago's critique that someone 
could change $TMPDIR.

Or one could avoid QDir::tempPath() in RuntimeLocation and use 
NSTemporaryDirectory instead, if tempPath() is supposed to return $TMPDIR in 
order to be under user control.

R.




More information about the Development mailing list