aboutsummaryrefslogtreecommitdiff
path: root/engines/agi
diff options
context:
space:
mode:
authorTarek Soliman2012-02-15 09:53:31 -0600
committerTarek Soliman2012-02-15 10:07:10 -0600
commita4798602d7a025dc13fd253d584dbf29dbec488d (patch)
treed6e764535eb4eef6d3c313e00a7eaea8b1724a2d /engines/agi
parent921f602ab8631a9d10e0a173b6b331dbafda564a (diff)
downloadscummvm-rg350-a4798602d7a025dc13fd253d584dbf29dbec488d.tar.gz
scummvm-rg350-a4798602d7a025dc13fd253d584dbf29dbec488d.tar.bz2
scummvm-rg350-a4798602d7a025dc13fd253d584dbf29dbec488d.zip
JANITORIAL: Fix missing whitespace in pointer cast
find -name '*.h' -or -name '*.cpp' | xargs sed -r -i 's@\(([A-Za-z0-9]+)\*\)@(\1 *)@g' This seems to have caught some params as well which is not undesirable IMO. It also caught some strings containing this which is undesirable so I excluded them manually. (engines/sci/engine/kernel_tables.h)
Diffstat (limited to 'engines/agi')
-rw-r--r--engines/agi/preagi_mickey.h2
-rw-r--r--engines/agi/preagi_troll.cpp4
-rw-r--r--engines/agi/sound_2gs.cpp6
-rw-r--r--engines/agi/sound_sarien.cpp4
-rw-r--r--engines/agi/sprite.cpp2
5 files changed, 9 insertions, 9 deletions
diff --git a/engines/agi/preagi_mickey.h b/engines/agi/preagi_mickey.h
index 673839a592..18b0593d78 100644
--- a/engines/agi/preagi_mickey.h
+++ b/engines/agi/preagi_mickey.h
@@ -704,7 +704,7 @@ protected:
void readOfsData(int, int, uint8*, long);
bool chooseY_N(int, bool);
int choose1to9(int);
- void printStr(char*);
+ void printStr(char *);
void printLine(const char*);
void printExeStr(int);
void printExeMsg(int);
diff --git a/engines/agi/preagi_troll.cpp b/engines/agi/preagi_troll.cpp
index 50b2945383..b7d2801076 100644
--- a/engines/agi/preagi_troll.cpp
+++ b/engines/agi/preagi_troll.cpp
@@ -455,7 +455,7 @@ int TrollEngine::drawRoom(char *menu) {
_gfx->doUpdate();
char tmp[10];
- strncat(menu, (char*)_gameData + _locMessagesIdx[_currentRoom], 39);
+ strncat(menu, (char *)_gameData + _locMessagesIdx[_currentRoom], 39);
for (int i = 0; i < 3; i++) {
if (_roomDescs[_roomPicture - 1].options[i]) {
@@ -725,7 +725,7 @@ void TrollEngine::fillOffsets() {
void TrollEngine::init() {
_picture->setPictureVersion(AGIPIC_V15);
- //SetScreenPar(320, 200, (char*)ibm_fontdata);
+ //SetScreenPar(320, 200, (char *)ibm_fontdata);
const int gaps[] = { 0x3A40, 0x4600, 0x4800, 0x5800, 0x5a00, 0x6a00,
0x6c00, 0x7400, 0x7600, 0x7c00, 0x7e00, 0x8e00,
diff --git a/engines/agi/sound_2gs.cpp b/engines/agi/sound_2gs.cpp
index b15950f31d..bfc8d4d8f3 100644
--- a/engines/agi/sound_2gs.cpp
+++ b/engines/agi/sound_2gs.cpp
@@ -68,10 +68,10 @@ int SoundGen2GS::readBuffer(int16 *buffer, const int numSamples) {
static uint data_available = 0;
static uint data_offset = 0;
uint n = numSamples << 1;
- uint8 *p = (uint8*)buffer;
+ uint8 *p = (uint8 *)buffer;
while (n > data_available) {
- memcpy(p, (uint8*)_out + data_offset, data_available);
+ memcpy(p, (uint8 *)_out + data_offset, data_available);
p += data_available;
n -= data_available;
@@ -81,7 +81,7 @@ int SoundGen2GS::readBuffer(int16 *buffer, const int numSamples) {
data_offset = 0;
}
- memcpy(p, (uint8*)_out + data_offset, n);
+ memcpy(p, (uint8 *)_out + data_offset, n);
data_offset += n;
data_available -= n;
diff --git a/engines/agi/sound_sarien.cpp b/engines/agi/sound_sarien.cpp
index a2baf89d12..576801bc56 100644
--- a/engines/agi/sound_sarien.cpp
+++ b/engines/agi/sound_sarien.cpp
@@ -330,7 +330,7 @@ void SoundGenSarien::fillAudio(int16 *stream, uint len) {
debugC(5, kDebugLevelSound, "(%p, %d)", (void *)stream, len);
while (len > data_available) {
- memcpy((uint8 *)stream + p, (uint8*)_sndBuffer + data_offset, data_available);
+ memcpy((uint8 *)stream + p, (uint8 *)_sndBuffer + data_offset, data_available);
p += data_available;
len -= data_available;
@@ -339,7 +339,7 @@ void SoundGenSarien::fillAudio(int16 *stream, uint len) {
data_offset = 0;
}
- memcpy((uint8 *)stream + p, (uint8*)_sndBuffer + data_offset, len);
+ memcpy((uint8 *)stream + p, (uint8 *)_sndBuffer + data_offset, len);
data_offset += len;
data_available -= len;
}
diff --git a/engines/agi/sprite.cpp b/engines/agi/sprite.cpp
index 8d13be3f68..ea2d329fb0 100644
--- a/engines/agi/sprite.cpp
+++ b/engines/agi/sprite.cpp
@@ -55,7 +55,7 @@ void *SpritesMgr::poolAlloc(int size) {
// Adjust size to sizeof(void *) boundary to prevent data misalignment
// errors.
- const int alignPadding = sizeof(void*) - 1;
+ const int alignPadding = sizeof(void *) - 1;
size = (size + alignPadding) & ~alignPadding;
x = _poolTop;