aboutsummaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorJeremy Lainé <jeremy.laine@m4x.org>2010-05-05 07:18:54 +0000
committerJeremy Lainé <jeremy.laine@m4x.org>2010-05-05 07:18:54 +0000
commit893234283ce5d470314ec1ea15274a64ca7cfe0e (patch)
treecbdd8bfc2379f94336adc4b2019a726ac249b2db /source
parent46e9ef5b3483cab5512c8b0464f946e4d4dfc26a (diff)
downloadqxmpp-893234283ce5d470314ec1ea15274a64ca7cfe0e.tar.gz
fix compilation errors with MS VC2008
Diffstat (limited to 'source')
-rw-r--r--source/QXmppClient.h2
-rw-r--r--source/QXmppTransferManager.cpp4
-rw-r--r--source/QXmppVCard.h2
3 files changed, 5 insertions, 3 deletions
diff --git a/source/QXmppClient.h b/source/QXmppClient.h
index 2c9f6050..f1225356 100644
--- a/source/QXmppClient.h
+++ b/source/QXmppClient.h
@@ -44,7 +44,7 @@ class QXmppVCardManager;
class QXmppInvokable;
class QXmppRpcInvokeIq;
class QXmppRemoteMethod;
-class QXmppRemoteMethodResult;
+struct QXmppRemoteMethodResult;
class QXmppArchiveManager;
class QXmppDiscoveryIq;
class QXmppTransferManager;
diff --git a/source/QXmppTransferManager.cpp b/source/QXmppTransferManager.cpp
index a31be400..5bbf3b22 100644
--- a/source/QXmppTransferManager.cpp
+++ b/source/QXmppTransferManager.cpp
@@ -284,16 +284,18 @@ void QXmppTransferJob::sendData()
return;
}
- char buffer[m_blockSize];
+ char *buffer = new char[m_blockSize];
qint64 length = m_iodevice->read(buffer, m_blockSize);
if (length < 0)
{
+ delete [] buffer;
terminate(QXmppTransferJob::FileAccessError);
return;
}
if (length > 0)
{
m_socksSocket->write(buffer, length);
+ delete [] buffer;
m_done += length;
emit progress(m_done, fileSize());
}
diff --git a/source/QXmppVCard.h b/source/QXmppVCard.h
index dce8066f..e59416dd 100644
--- a/source/QXmppVCard.h
+++ b/source/QXmppVCard.h
@@ -63,7 +63,7 @@ public:
QString Q_DECL_DEPRECATED getFullName() const;
QString Q_DECL_DEPRECATED getNickName() const;
QImage Q_DECL_DEPRECATED getPhotoAsImage() const;
- const QByteArray& Q_DECL_DEPRECATED getPhoto() const;
+ const QByteArray Q_DECL_DEPRECATED & getPhoto() const;
// obsolete end
private: