Fix uses of uninitialized variables

- Replace unknown008 array with two separate variables in Object code

- Fix mismatched safe_delete() of an array
This commit is contained in:
j883376
2013-06-25 23:40:05 -04:00
parent 7e2806119b
commit 488b2888a8
9 changed files with 49 additions and 49 deletions
-2
View File
@@ -2044,7 +2044,6 @@ ENCODE(OP_ZonePlayerToBind)
ZonePlayerToBind_Struct *zps = (ZonePlayerToBind_Struct*)(*p)->pBuffer;
std::stringstream ss(std::stringstream::in | std::stringstream::out | std::stringstream::binary);
ss.clear();
unsigned char *buffer1 = new unsigned char[sizeof(structs::ZonePlayerToBindHeader_Struct) + strlen(zps->zone_name)];
structs::ZonePlayerToBindHeader_Struct *zph = (structs::ZonePlayerToBindHeader_Struct*)buffer1;
@@ -3462,7 +3461,6 @@ char* SerializeItem(const ItemInst *inst, int16 slot_id_in, uint32 *length, uint
charges = 0xFFFFFFFF;
std::stringstream ss(std::stringstream::in | std::stringstream::out | std::stringstream::binary);
ss.clear();
const Item_Struct *item = inst->GetItem();
//_log(NET__ERROR, "Serialize called for: %s", item->Name);