aboutsummaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authortwinaphex2016-08-06 04:31:04 +0200
committertwinaphex2016-08-06 04:31:04 +0200
commit89aaca592b0b40ce17e1d80548986be6e00323ee (patch)
treef0ed9abb11375b8b86d530ee8fc5fd1676c85a49 /source
parent89827cd2c8a3f9ca55c4778261e35c218471cbe0 (diff)
downloadsnes9x2005-89aaca592b0b40ce17e1d80548986be6e00323ee.tar.gz
snes9x2005-89aaca592b0b40ce17e1d80548986be6e00323ee.tar.bz2
snes9x2005-89aaca592b0b40ce17e1d80548986be6e00323ee.zip
Cleanups
Diffstat (limited to 'source')
-rw-r--r--source/memmap.c28
-rw-r--r--source/memmap.h7
2 files changed, 14 insertions, 21 deletions
diff --git a/source/memmap.c b/source/memmap.c
index 12a2365..257b4ec 100644
--- a/source/memmap.c
+++ b/source/memmap.c
@@ -142,7 +142,16 @@ static int retry_count = 0;
static uint8_t bytes0x2000 [0x2000];
int is_bsx(unsigned char*);
int bs_name(unsigned char*);
-int check_char(unsigned);
+
+static int check_char(unsigned c)
+{
+ if ((c & 0x80) == 0)
+ return 0;
+ if ((c - 0x20) & 0x40)
+ return 1;
+ return 0;
+}
+
void S9xDeinterleaveType2(bool reset);
uint32_t caCRC32(uint8_t* array, uint32_t size, register uint32_t crc32);
@@ -273,7 +282,7 @@ void S9xDeinterleaveGD24(int TotalFileSize, uint8_t* base)
}
}
-bool AllASCII(uint8_t* b, int size)
+static bool AllASCII(uint8_t* b, int size)
{
int i;
for (i = 0; i < size; i++)
@@ -284,7 +293,7 @@ bool AllASCII(uint8_t* b, int size)
return (true);
}
-int ScoreHiROM(bool skip_header, int32_t romoff)
+static int ScoreHiROM(bool skip_header, int32_t romoff)
{
int score = 0;
int o = skip_header ? 0xff00 + 0x200 : 0xff00;
@@ -329,7 +338,7 @@ int ScoreHiROM(bool skip_header, int32_t romoff)
return (score);
}
-int ScoreLoROM(bool skip_header, int32_t romoff)
+static int ScoreLoROM(bool skip_header, int32_t romoff)
{
int score = 0;
int o = skip_header ? 0x7f00 + 0x200 : 0x7f00;
@@ -371,7 +380,7 @@ int ScoreLoROM(bool skip_header, int32_t romoff)
return (score);
}
-char* Safe(const char* s)
+static char* Safe(const char* s)
{
static char* safe;
static int safe_len = 0;
@@ -4219,15 +4228,6 @@ int bs_name(unsigned char* p)
notBsName:
return -1;
}
-int check_char(unsigned c)
-{
- if ((c & 0x80) == 0)
- return 0;
- if ((c - 0x20) & 0x40)
- return 1;
- else
- return 0;
-}
void ParseSNESHeader(uint8_t* RomHeader)
{
diff --git a/source/memmap.h b/source/memmap.h
index c8ac641..02882bf 100644
--- a/source/memmap.h
+++ b/source/memmap.h
@@ -151,7 +151,6 @@ void WriteProtectROM();
void FixROMSpeed();
void MapRAM();
void MapExtraRAM();
-char* Safe(const char*);
void BSLoROMMap();
void JumboLoROMMap(bool);
@@ -169,12 +168,6 @@ void BSHiROMMap();
void SPC7110HiROMMap();
void SPC7110Sram(uint8_t);
void SetaDSPMap();
-bool AllASCII(uint8_t* b, int size);
-int ScoreHiROM(bool skip_header, int32_t offset);
-int ScoreLoROM(bool skip_header, int32_t offset);
-#if 0
-void SufamiTurboAltROMMap();
-#endif
void ApplyROMFixes();
const char* TVStandard();