From 302029e093c88fb46cea8d6131726b82731110f9 Mon Sep 17 00:00:00 2001 From: Hugo Lima Date: Mon, 23 Nov 2009 16:51:01 -0200 Subject: Change the getGenerators signature, because on some platforms a function exported as a C function can't return a C++ type by value. All generators plugins *MUST* be recompiled. Reviewed by Luciano Wolf --- main.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'main.cpp') diff --git a/main.cpp b/main.cpp index af0609345..7c690294d 100644 --- a/main.cpp +++ b/main.cpp @@ -48,7 +48,7 @@ static void printOptions(QTextStream& s, const QMap& options) } } -typedef QLinkedList (*getGeneratorsFunc)(); +typedef void (*getGeneratorsFunc)(QLinkedList*); QMap getCommandLineArgs(int argc, char** argv) { @@ -129,7 +129,7 @@ int main(int argc, char *argv[]) QLibrary plugin(generatorFile); getGeneratorsFunc getGenerators = (getGeneratorsFunc)plugin.resolve("getGenerators"); if (getGenerators) - generators = getGenerators(); + getGenerators(&generators); else { std::cerr << argv[0] << ": Error loading generatorset plugin: " << qPrintable(plugin.errorString()) << std::endl; return EXIT_FAILURE; -- cgit v1.2.3