Mercurial > octave
changeset 25101:29641449ca90 stable
use qt routines for determining users tmp directory (bug #53006)
* documentation.cc (documentation): use QDir::tempPath() for getting
users tmp directory
author | Torsten <mttl@mailbox.org> |
---|---|
date | Tue, 03 Apr 2018 21:48:33 +0200 |
parents | daff5efe062f |
children | 65b7380655f2 |
files | libgui/src/documentation.cc |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/libgui/src/documentation.cc Tue Apr 03 08:14:48 2018 -0400 +++ b/libgui/src/documentation.cc Tue Apr 03 21:48:33 2018 +0200 @@ -64,9 +64,10 @@ // of the original collection and load the help data m_help_engine = new QHelpEngine (collection, this); - std::string tmpdir (octave::sys::env::getenv ("TMPDIR")); + QString tmpdir = QDir::tempPath(); m_collection - = QString::fromStdString (octave::sys::tempnam (tmpdir, "oct-qhelp-")); + = QString::fromStdString (octave::sys::tempnam (tmpdir.toStdString (), + "oct-qhelp-")); if (m_help_engine->copyCollectionFile (m_collection)) m_help_engine->setCollectionFile (m_collection);