mirror of
https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git
synced 2025-07-18 19:29:09 +00:00
Convert custom HeadSpin integer types to standard types from stdint.h
This commit is contained in:
@ -125,12 +125,12 @@ void hsReadOnlyLoggingStream::FastFwd()
|
||||
hsThrow( "can't fast forward a logging stream");
|
||||
}
|
||||
|
||||
void hsReadOnlyLoggingStream::SetPosition(UInt32 position)
|
||||
void hsReadOnlyLoggingStream::SetPosition(uint32_t position)
|
||||
{
|
||||
hsThrow( "can't set position on a logging stream");
|
||||
}
|
||||
|
||||
void hsReadOnlyLoggingStream::Skip(UInt32 deltaByteCount)
|
||||
void hsReadOnlyLoggingStream::Skip(uint32_t deltaByteCount)
|
||||
{
|
||||
hsReadOnlyStream::Skip(deltaByteCount);
|
||||
if (deltaByteCount > 0 && !IsLogEntryWaiting())
|
||||
@ -139,9 +139,9 @@ void hsReadOnlyLoggingStream::Skip(UInt32 deltaByteCount)
|
||||
}
|
||||
}
|
||||
|
||||
UInt32 hsReadOnlyLoggingStream::Read(UInt32 byteCount, void * buffer)
|
||||
uint32_t hsReadOnlyLoggingStream::Read(uint32_t byteCount, void * buffer)
|
||||
{
|
||||
UInt32 ret = hsReadOnlyStream::Read(byteCount,buffer);
|
||||
uint32_t ret = hsReadOnlyStream::Read(byteCount,buffer);
|
||||
if (ret > 0 && !IsLogEntryWaiting())
|
||||
{
|
||||
LogEntry(plGenericType::kNone,byteCount,nil,"Unknown Read");
|
||||
@ -151,7 +151,7 @@ UInt32 hsReadOnlyLoggingStream::Read(UInt32 byteCount, void * buffer)
|
||||
}
|
||||
|
||||
|
||||
void hsReadOnlyLoggingStream::LogSkip(UInt32 deltaByteCount, const char* desc)
|
||||
void hsReadOnlyLoggingStream::LogSkip(uint32_t deltaByteCount, const char* desc)
|
||||
{
|
||||
ILogEntryWaiting();
|
||||
Skip(deltaByteCount);
|
||||
@ -161,10 +161,10 @@ void hsReadOnlyLoggingStream::LogSkip(UInt32 deltaByteCount, const char* desc)
|
||||
}
|
||||
}
|
||||
|
||||
UInt32 hsReadOnlyLoggingStream::LogRead(UInt32 byteCount, void * buffer, const char* desc)
|
||||
uint32_t hsReadOnlyLoggingStream::LogRead(uint32_t byteCount, void * buffer, const char* desc)
|
||||
{
|
||||
ILogEntryWaiting();
|
||||
UInt32 ret = Read(byteCount,buffer);
|
||||
uint32_t ret = Read(byteCount,buffer);
|
||||
if (ret > 0)
|
||||
{
|
||||
LogEntry(plGenericType::kNone,byteCount,nil,desc);
|
||||
@ -175,7 +175,7 @@ UInt32 hsReadOnlyLoggingStream::LogRead(UInt32 byteCount, void * buffer, const c
|
||||
char *hsReadOnlyLoggingStream::LogReadSafeString()
|
||||
{
|
||||
LogSubStreamStart("push me");
|
||||
UInt16 numChars;
|
||||
uint16_t numChars;
|
||||
LogReadLE(&numChars,"NumChars");
|
||||
|
||||
numChars &= ~0xf000; // XXX: remove when hsStream no longer does this.
|
||||
@ -183,7 +183,7 @@ char *hsReadOnlyLoggingStream::LogReadSafeString()
|
||||
{
|
||||
char *name = TRACKED_NEW char[numChars+1];
|
||||
ILogEntryWaiting();
|
||||
UInt32 ret = Read(numChars, name);
|
||||
uint32_t ret = Read(numChars, name);
|
||||
name[numChars] = '\0';
|
||||
if (ret > 0)
|
||||
{
|
||||
@ -199,13 +199,13 @@ char *hsReadOnlyLoggingStream::LogReadSafeString()
|
||||
char *hsReadOnlyLoggingStream::LogReadSafeStringLong()
|
||||
{
|
||||
LogSubStreamStart("push me");
|
||||
UInt32 numChars;
|
||||
uint32_t numChars;
|
||||
LogReadLE(&numChars,"NumChars");
|
||||
if (numChars > 0)
|
||||
{
|
||||
char *name = TRACKED_NEW char[numChars+1];
|
||||
ILogEntryWaiting();
|
||||
UInt32 ret = Read(numChars, name);
|
||||
uint32_t ret = Read(numChars, name);
|
||||
name[numChars] = '\0';
|
||||
if (ret > 0)
|
||||
{
|
||||
|
@ -113,37 +113,37 @@ private:
|
||||
public:
|
||||
void Rewind();
|
||||
void FastFwd();
|
||||
void SetPosition(UInt32 position);
|
||||
void SetPosition(uint32_t position);
|
||||
|
||||
UInt32 Read(UInt32 byteCount, void * buffer);
|
||||
void Skip(UInt32 deltaByteCount);
|
||||
uint32_t Read(uint32_t byteCount, void * buffer);
|
||||
void Skip(uint32_t deltaByteCount);
|
||||
|
||||
UInt32 LogRead(UInt32 byteCount, void * buffer, const char* desc);
|
||||
uint32_t LogRead(uint32_t byteCount, void * buffer, const char* desc);
|
||||
char* LogReadSafeString();
|
||||
char* LogReadSafeStringLong();
|
||||
void LogSkip(UInt32 deltaByteCount, const char* desc);
|
||||
void LogSkip(uint32_t deltaByteCount, const char* desc);
|
||||
void LogStringString(const char* s);
|
||||
void LogSubStreamStart(const char* desc);
|
||||
void LogSubStreamEnd();
|
||||
void LogSubStreamPushDesc(const char* desc);
|
||||
|
||||
LOG_READ_LE(bool, kBool)
|
||||
LOG_READ_LE(UInt8, kUInt)
|
||||
LOG_READ_LE(UInt16, kUInt)
|
||||
LOG_READ_LE(UInt32, kUInt)
|
||||
LOG_READ_LE_ARRAY(UInt8, kUInt)
|
||||
LOG_READ_LE_ARRAY(UInt16, kUInt)
|
||||
LOG_READ_LE_ARRAY(UInt32, kUInt)
|
||||
LOG_READ_LE(uint8_t, kUInt)
|
||||
LOG_READ_LE(uint16_t, kUInt)
|
||||
LOG_READ_LE(uint32_t, kUInt)
|
||||
LOG_READ_LE_ARRAY(uint8_t, kUInt)
|
||||
LOG_READ_LE_ARRAY(uint16_t, kUInt)
|
||||
LOG_READ_LE_ARRAY(uint32_t, kUInt)
|
||||
|
||||
LOG_READ_LE(Int8, kInt)
|
||||
LOG_READ_LE(int8_t, kInt)
|
||||
LOG_READ_LE(char, kChar)
|
||||
LOG_READ_LE(Int16, kInt)
|
||||
LOG_READ_LE(Int32, kInt)
|
||||
LOG_READ_LE(int16_t, kInt)
|
||||
LOG_READ_LE(int32_t, kInt)
|
||||
LOG_READ_LE(int, kInt)
|
||||
LOG_READ_LE_ARRAY(Int8, kInt)
|
||||
LOG_READ_LE_ARRAY(int8_t, kInt)
|
||||
LOG_READ_LE_ARRAY(char, kChar)
|
||||
LOG_READ_LE_ARRAY(Int16, kInt)
|
||||
LOG_READ_LE_ARRAY(Int32, kInt)
|
||||
LOG_READ_LE_ARRAY(int16_t, kInt)
|
||||
LOG_READ_LE_ARRAY(int32_t, kInt)
|
||||
LOG_READ_LE_ARRAY(int, kInt)
|
||||
|
||||
LOG_READ_LE(float, kFloat)
|
||||
|
Reference in New Issue
Block a user