fix more warnings

This commit is contained in:
DarthArgus
2014-10-27 18:59:37 -07:00
parent 9e6f200300
commit 7b6271b48d
26 changed files with 71 additions and 170 deletions
@@ -92,7 +92,7 @@ RemoteDebug::Variable::Variable(const std::string& name, void *memLoc, VARIABLE_
break;
case CSTRING:
m_value.stringValue = &s;
m_value.stringValue = s;
break;
case BOOL:
@@ -229,7 +229,7 @@ int FileStreamer::File::read(int offset, void *destinationBuffer, int numberOfBy
newRequest->bytesRead = 0;
newRequest->gate = gate;
newRequest->priority = priority;
newRequest->returnValue = &returnValue;
newRequest->returnValue = returnValue;
// submit the request
FileStreamerThread::submitRequest(newRequest);
@@ -115,7 +115,7 @@ public:
AbstractFile::PriorityType priority;
// storage held by game thread used to pass back return value
int *returnValue;
int returnValue;
public:
@@ -604,7 +604,6 @@ void Iff::adjustDataAsNeeded(int size)
// allocate the new memory
DEBUG_FATAL(newLength < 0, ("negative array allocation"));
byte *newData = new byte[static_cast<size_t>(newLength)];
NOT_NULL(newData);
// copy the old data over to the new data
memcpy(newData, data, stack[0].length);
@@ -97,8 +97,6 @@ XmlTreeDocument* XmlTreeDocument::createDocument(const char * rootNodeName)
xmlDocSetRootElement(doc, node);
XmlTreeDocument *treeDoc = new XmlTreeDocument(doc);
DEBUG_WARNING( !treeDoc, ("Attempted to make new XmlTreeDoc but failed") );
xmlFree(doc);
return 0;