summaryrefslogtreecommitdiffstats
path: root/examples/applicationmanager/custom-appman/custom-appman.cpp
diff options
context:
space:
mode:
authorRobert Griebl <robert.griebl@pelagicore.com>2019-01-16 17:24:09 +0100
committerDominik Holland <dominik.holland@pelagicore.com>2019-01-16 19:36:50 +0000
commitae4600abc21abb2dc4f19e1f76feeb1c3f77cfe5 (patch)
tree4452baf2001521708ee959990887a7f6cc5b14d1 /examples/applicationmanager/custom-appman/custom-appman.cpp
parentd6fadebe29a28fcee1cacd26081a698938b7a566 (diff)
Fixing more UTF-8 problems on macOS: runtime errors in libarchive
When running auto-tests or appman tools in a shell with LC_CTYPE/LC_ALL not being set or being set to a non-UTF-8 value, libarchive will not be able to read a from an archive with UTF-8 encoded names. We're now using the same code path as on Linux to detect and workaround these situations. In addition, a DeploymentWarning is generated if the default locale is not suitable. (also needed to fix the custom appman example and its docs) Change-Id: Ib2936fafead518a66efffc2e7bedceb7c46836d3 Reviewed-by: Dominik Holland <dominik.holland@pelagicore.com>
Diffstat (limited to 'examples/applicationmanager/custom-appman/custom-appman.cpp')
-rw-r--r--examples/applicationmanager/custom-appman/custom-appman.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/examples/applicationmanager/custom-appman/custom-appman.cpp b/examples/applicationmanager/custom-appman/custom-appman.cpp
index dbd002bd..38e0a98f 100644
--- a/examples/applicationmanager/custom-appman/custom-appman.cpp
+++ b/examples/applicationmanager/custom-appman/custom-appman.cpp
@@ -67,19 +67,16 @@ Q_DECL_EXPORT int main(int argc, char *argv[])
QCoreApplication::setApplicationVersion("0.1");
Logging::initialize(argc, argv);
-
Package::ensureCorrectLocale();
+ Sudo::forkServer(Sudo::DropPrivilegesPermanently);
try {
- QStringList deploymentWarnings;
- Sudo::forkServer(Sudo::DropPrivilegesPermanently, &deploymentWarnings);
-
Main a(argc, argv);
DefaultConfiguration cfg;
cfg.parse();
- a.setup(&cfg, deploymentWarnings);
+ a.setup(&cfg);
a.loadQml(cfg.loadDummyData());
a.showWindow(cfg.fullscreen() && !cfg.noFullscreen());