diff options
author | Ulf Hermann <ulf.hermann@theqtcompany.com> | 2015-06-11 17:39:15 +0200 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@theqtcompany.com> | 2015-06-12 11:57:07 +0000 |
commit | 2cbd318f1da432024dc724a644da98da2b52692b (patch) | |
tree | ff6aa56d0a33324356382edaba09579f7d67c9af /src/printsupport/kernel | |
parent | 7f85fb4654f0d6f9058336af53148d81fc700497 (diff) |
Don't try to load plugins if QT_NO_LIBRARY is set.
Any plugin loading is impossible then and the code won't even compile.
Change-Id: I81e49ff87ae1a609521d526f5098a0d44cc28f7c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Diffstat (limited to 'src/printsupport/kernel')
-rw-r--r-- | src/printsupport/kernel/qplatformprintplugin.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/printsupport/kernel/qplatformprintplugin.cpp b/src/printsupport/kernel/qplatformprintplugin.cpp index 091cc6f008..9adf39ffcd 100644 --- a/src/printsupport/kernel/qplatformprintplugin.cpp +++ b/src/printsupport/kernel/qplatformprintplugin.cpp @@ -55,6 +55,7 @@ QPlatformPrinterSupportPlugin::~QPlatformPrinterSupportPlugin() static QPlatformPrinterSupport *printerSupport = 0; +#ifndef QT_NO_LIBRARY static void cleanupPrinterSupport() { #ifndef QT_NO_PRINTER @@ -62,6 +63,7 @@ static void cleanupPrinterSupport() #endif printerSupport = 0; } +#endif // !QT_NO_LIBRARY /*! \internal @@ -73,6 +75,7 @@ static void cleanupPrinterSupport() */ QPlatformPrinterSupport *QPlatformPrinterSupportPlugin::get() { +#ifndef QT_NO_LIBRARY if (!printerSupport) { const QMultiMap<int, QString> keyMap = loader()->keyMap(); if (!keyMap.isEmpty()) @@ -80,6 +83,7 @@ QPlatformPrinterSupport *QPlatformPrinterSupportPlugin::get() if (printerSupport) qAddPostRoutine(cleanupPrinterSupport); } +#endif // !QT_NO_LIBRARY return printerSupport; } |