Add [[maybe_unused]] to avoid compilation warnings on Android
When cross compiling for Android, these need to be marked with [[maybe_unused]] as they might break the build due to Android not having pthread cancellation feature. Pick-to: 6.5 Change-Id: I3b3fb58b5e6df8ce37c2d8d9b1b8e8295f0aebb0 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
parent
11491fcc5f
commit
69b69a7bcc
@ -529,7 +529,7 @@ void QProcessPrivate::startProcess()
|
||||
// Disable PThread cancellation from this point on: we mustn't have it
|
||||
// enabled when the child starts running nor while our state could get
|
||||
// corrupted if we abruptly exited this function.
|
||||
PThreadCancelGuard cancelGuard;
|
||||
[[maybe_unused]] PThreadCancelGuard cancelGuard;
|
||||
|
||||
// Start the child.
|
||||
auto execChild1 = [this, workingDirFd, &argv, &envp]() {
|
||||
@ -1088,7 +1088,7 @@ bool QProcessPrivate::startDetached(qint64 *pid)
|
||||
const CharPointerList envp(environment.d.constData());
|
||||
|
||||
// see startProcess() for more information
|
||||
PThreadCancelGuard cancelGuard;
|
||||
[[maybe_unused]] PThreadCancelGuard cancelGuard;
|
||||
|
||||
auto doFork = [this]() {
|
||||
if (useForkFlags(unixExtras.get()))
|
||||
|
Loading…
x
Reference in New Issue
Block a user