diff options
Diffstat (limited to 'Swiften/Elements')
| -rw-r--r-- | Swiften/Elements/IBB.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/Swiften/Elements/IBB.h b/Swiften/Elements/IBB.h index bd0b661..6ebe66e 100644 --- a/Swiften/Elements/IBB.h +++ b/Swiften/Elements/IBB.h @@ -1,8 +1,8 @@ /* - * Copyright (c) 2010-2016 Isode Limited. + * Copyright (c) 2010-2018 Isode Limited. * All rights reserved. * See the COPYING file for more information. */ #pragma once @@ -25,16 +25,16 @@ namespace Swift { }; enum StanzaType { IQStanza, MessageStanza }; - IBB(Action action = Open, const std::string& streamID = "") : action(action), streamID(streamID), stanzaType(IQStanza), blockSize(-1), sequenceNumber(-1) { + IBB(Action action = Open, const std::string& streamID = "") : action(action), streamID(streamID), stanzaType(IQStanza), blockSize(0), sequenceNumber(-1) { } - static IBB::ref createIBBOpen(const std::string& streamID, int blockSize) { + static IBB::ref createIBBOpen(const std::string& streamID, unsigned int blockSize) { IBB::ref result = std::make_shared<IBB>(Open, streamID); result->setBlockSize(blockSize); return result; } static IBB::ref createIBBData(const std::string& streamID, int sequenceNumber, const std::vector<unsigned char>& data) { @@ -77,17 +77,17 @@ namespace Swift { } void setData(const std::vector<unsigned char>& data) { this->data = data; } - int getBlockSize() const { + unsigned int getBlockSize() const { return blockSize; } - void setBlockSize(int blockSize) { + void setBlockSize(unsigned int blockSize) { this->blockSize = blockSize; } int getSequenceNumber() const { return sequenceNumber; } @@ -98,10 +98,10 @@ namespace Swift { private: Action action; std::string streamID; std::vector<unsigned char> data; StanzaType stanzaType; - int blockSize; + unsigned int blockSize; int sequenceNumber; }; } |
Swift