summaryrefslogtreecommitdiff
path: root/src/net/messageout.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/net/messageout.cpp')
-rw-r--r--src/net/messageout.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/net/messageout.cpp b/src/net/messageout.cpp
index d25cc62b..aa7f06c4 100644
--- a/src/net/messageout.cpp
+++ b/src/net/messageout.cpp
@@ -37,7 +37,7 @@ MessageOut::MessageOut():
{
// TODO: data not to be already allocated, keep it this way unitl full
// conversion
- mData = out;
+ mData = out + out_size;
}
MessageOut::~MessageOut()
@@ -54,8 +54,8 @@ MessageOut::~MessageOut()
void MessageOut::expand(size_t bytes)
{
- mData = (char*)realloc(mData, bytes);
- mDataSize = bytes;
+ /*mData = (char*)realloc(mData, bytes);
+ mDataSize = bytes;*/
}
void MessageOut::writeByte(char value)
@@ -97,8 +97,6 @@ void MessageOut::writeString(const std::string &string, int length)
{
// Write the length at the start if not fixed
writeShort(string.length());
- toWrite = string;
-
expand(mPos + string.length());
}
else