SecBSD's official ports repository
This commit is contained in:
commit
2c0afcbbf3
64331 changed files with 5339189 additions and 0 deletions
|
@ -0,0 +1,57 @@
|
|||
Index: lxqt-session/src/lxqtmodman.cpp
|
||||
--- lxqt-session/src/lxqtmodman.cpp.orig
|
||||
+++ lxqt-session/src/lxqtmodman.cpp
|
||||
@@ -26,6 +26,10 @@
|
||||
*
|
||||
* END_COMMON_COPYRIGHT_HEADER */
|
||||
|
||||
+#if defined(__OpenBSD__)
|
||||
+#define NO_WORDEXP
|
||||
+#endif
|
||||
+
|
||||
#include "lxqtmodman.h"
|
||||
#include <LXQt/Globals>
|
||||
#include <LXQt/Settings>
|
||||
@@ -43,7 +47,11 @@
|
||||
#include <QDateTime>
|
||||
#include "wmselectdialog.h"
|
||||
#include "windowmanager.h"
|
||||
+#ifdef NO_WORDEXP
|
||||
+#include <glob.h>
|
||||
+#else
|
||||
#include <wordexp.h>
|
||||
+#endif
|
||||
#include "log.h"
|
||||
|
||||
#include <KWindowSystem/KWindowSystem>
|
||||
@@ -429,6 +437,22 @@ bool LXQtModuleManager::nativeEventFilter(const QByteA
|
||||
|
||||
void lxqt_setenv(const char *env, const QByteArray &value)
|
||||
{
|
||||
+ #ifdef NO_WORDEXP
|
||||
+ glob_t p;
|
||||
+ glob(value.constData(), 0, NULL, &p);
|
||||
+ if (p.gl_pathc == 1)
|
||||
+ {
|
||||
+
|
||||
+ qCDebug(SESSION) << "Environment variable" << env << "=" << p.gl_pathv[0];
|
||||
+ qputenv(env, p.gl_pathv[0]);
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ qCWarning(SESSION) << "Error expanding environment variable" << env << "=" << value;
|
||||
+ qputenv(env, value);
|
||||
+ }
|
||||
+ globfree(&p);
|
||||
+ #else
|
||||
wordexp_t p;
|
||||
wordexp(value.constData(), &p, 0);
|
||||
if (p.we_wordc == 1)
|
||||
@@ -443,6 +467,7 @@ void lxqt_setenv(const char *env, const QByteArray &va
|
||||
qputenv(env, value);
|
||||
}
|
||||
wordfree(&p);
|
||||
+ #endif
|
||||
}
|
||||
|
||||
void lxqt_setenv_prepend(const char *env, const QByteArray &value, const QByteArray &separator)
|
Loading…
Add table
Add a link
Reference in a new issue