summaryrefslogtreecommitdiffstats
path: root/kopete/protocols/yahoo/libkyahoo/inputprotocolbase.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-05 08:45:53 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-05 08:45:53 +0000
commit5527e01e0675fbb06b632ccdae423756fbff622b (patch)
treec2dd1a478a7789d3b01e77fdf31f9011a96a81c5 /kopete/protocols/yahoo/libkyahoo/inputprotocolbase.cpp
parent1fc8db48741fae272e2d29078b266a3d0f2e2dd1 (diff)
downloadtdenetwork-5527e01e0675fbb06b632ccdae423756fbff622b.tar.gz
tdenetwork-5527e01e0675fbb06b632ccdae423756fbff622b.zip
Many fixes to the Yahoo protocol, courtesy of Serghei Amelian
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1146108 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kopete/protocols/yahoo/libkyahoo/inputprotocolbase.cpp')
-rw-r--r--kopete/protocols/yahoo/libkyahoo/inputprotocolbase.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/kopete/protocols/yahoo/libkyahoo/inputprotocolbase.cpp b/kopete/protocols/yahoo/libkyahoo/inputprotocolbase.cpp
index 5c2dfcc3..eca3318a 100644
--- a/kopete/protocols/yahoo/libkyahoo/inputprotocolbase.cpp
+++ b/kopete/protocols/yahoo/libkyahoo/inputprotocolbase.cpp
@@ -18,6 +18,7 @@
#include "inputprotocolbase.h"
+
InputProtocolBase::InputProtocolBase(QObject *parent, const char *name)
: QObject(parent, name)
{
@@ -59,6 +60,7 @@ bool InputProtocolBase::okToProceed()
return false;
}
+// FIXME: need to be checked
bool InputProtocolBase::safeReadBytes( QCString & data, uint & len )
{
// read the length of the bytes
@@ -81,8 +83,8 @@ bool InputProtocolBase::safeReadBytes( QCString & data, uint & len )
// the rest of the string will be filled with FF,
// so look for that in the last position instead of \0
// this caused a crash - guessing that temp.length() is set to the number of bytes actually read...
- // if ( (Q_UINT8)( * ( temp.data() + ( temp.length() - 1 ) ) ) == 0xFF )
- if ( temp.length() < ( val - 1 ) )
+ // if ( (quint8)( * ( temp.data() + ( temp.length() - 1 ) ) ) == 0xFF )
+ if ( temp.length() < static_cast<int>( val - 1 ) )
{
qDebug( "InputProtocol::safeReadBytes() - string broke, giving up, only got: %i bytes out of %i", temp.length(), val );
m_state = NeedMore;