From: APTX Date: Fri, 21 Jan 2011 22:52:06 +0000 (+0100) Subject: Fix gcc warnings/errors X-Git-Url: https://gitweb.tyo.aptx.org/?a=commitdiff_plain;h=refs%2Fheads%2Frename-tool;p=anidbudpclient.git Fix gcc warnings/errors --- diff --git a/abstractcommand.h b/abstractcommand.h index 1a7ce59..0484608 100644 --- a/abstractcommand.h +++ b/abstractcommand.h @@ -40,7 +40,7 @@ typedef name##Command CommandType; \ private: \ CommandType m_command; \ Client *m_client; \ -name##Reply(const CommandType command, const QByteArray &id, Client *client, QObject *parent) : m_command(command), m_client(client), AbstractReply(id, client, parent) {constructor} \ +name##Reply(const CommandType command, const QByteArray &id, Client *client, QObject *parent) : AbstractReply(id, client, parent), m_command(command), m_client(client) {constructor} \ inline const CommandType &command() const { return m_command; } #define REPLY_DEFINITION_HELPER(name) \ diff --git a/clientqueuedcommandsmodel.cpp b/clientqueuedcommandsmodel.cpp index 58bd1e0..11aad98 100644 --- a/clientqueuedcommandsmodel.cpp +++ b/clientqueuedcommandsmodel.cpp @@ -5,7 +5,7 @@ namespace AniDBUdpClient { ClientQueuedCommandsModel::ClientQueuedCommandsModel(Client *client, QObject *parent) : - m_client(0), QAbstractTableModel(parent) + QAbstractTableModel(parent), m_client(0) { setClient(client); } diff --git a/clientsentcommandsmodel.cpp b/clientsentcommandsmodel.cpp index 1da5715..4df0150 100644 --- a/clientsentcommandsmodel.cpp +++ b/clientsentcommandsmodel.cpp @@ -5,7 +5,7 @@ namespace AniDBUdpClient { ClientSentCommandsModel::ClientSentCommandsModel(Client *client, QObject *parent) : - m_client(0), QAbstractTableModel(parent) + QAbstractTableModel(parent), m_client(0) { setClient(client); } diff --git a/file.cpp b/file.cpp index 19dbc4e..c58ab99 100644 --- a/file.cpp +++ b/file.cpp @@ -437,6 +437,8 @@ void File::updateStatus(Action action, ActionState actionState) break; case MarkingWatched: m_markingState = actionState; + default: + return; } emit statusUpdate(action, actionState); } diff --git a/renameparser/ECMAScript/parser.cpp b/renameparser/ECMAScript/parser.cpp index 46feaa4..117772e 100644 --- a/renameparser/ECMAScript/parser.cpp +++ b/renameparser/ECMAScript/parser.cpp @@ -55,7 +55,7 @@ QString Parser::evaluate(Environment &env) const { fct->activationObject().setProperty(funcName, engine.newFunction( - &RenameEngine2QtScriptHelper, RenameEngine::function(funcName))); + &RenameEngine2QtScriptHelper, (void *) RenameEngine::function(funcName))); } QScriptContext *ct = engine.pushContext();