mirror of
https://github.com/sanni/cartreader.git
synced 2024-12-25 04:21:53 +01:00
Merge pull request #336 from Kreeblah/warning_fixes
Fixed build warnings
This commit is contained in:
commit
3116321b36
@ -1411,7 +1411,7 @@ void identifyCFI_GB() {
|
|||||||
println_Msg(F("CFI Query failed!"));
|
println_Msg(F("CFI Query failed!"));
|
||||||
display_Update();
|
display_Update();
|
||||||
wait();
|
wait();
|
||||||
return 0;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
dataIn_GB();
|
dataIn_GB();
|
||||||
|
@ -851,7 +851,7 @@ unsigned char* getNESHeaderForFileInfo(uint32_t prg_size, uint32_t chr_size, uin
|
|||||||
}
|
}
|
||||||
|
|
||||||
char* temp_line;
|
char* temp_line;
|
||||||
char* nes20_header;
|
unsigned char* nes20_header;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
if (!sdFile.open("/nes20db.txt", FILE_READ)) {
|
if (!sdFile.open("/nes20db.txt", FILE_READ)) {
|
||||||
@ -862,7 +862,7 @@ unsigned char* getNESHeaderForFileInfo(uint32_t prg_size, uint32_t chr_size, uin
|
|||||||
display_Update();
|
display_Update();
|
||||||
}
|
}
|
||||||
|
|
||||||
temp_line = malloc(256 * sizeof(char));
|
temp_line = (char*)malloc(256 * sizeof(char));
|
||||||
while (sdFile.available()) {
|
while (sdFile.available()) {
|
||||||
// We're reading fixed-length lines
|
// We're reading fixed-length lines
|
||||||
// padded with null characters
|
// padded with null characters
|
||||||
|
@ -67,7 +67,7 @@ static const char pceCartMenuItem4[] = "Reset";
|
|||||||
static const char pceCartMenuItem5[] = "Inc Bank Number";
|
static const char pceCartMenuItem5[] = "Inc Bank Number";
|
||||||
static const char pceCartMenuItem6[] = "Dec Bank Number";
|
static const char pceCartMenuItem6[] = "Dec Bank Number";
|
||||||
static char pceCartMenuItem7[20];
|
static char pceCartMenuItem7[20];
|
||||||
static const char menuOptionspceCart[7][20];
|
static char menuOptionspceCart[7][20];
|
||||||
|
|
||||||
// Turbochip menu items
|
// Turbochip menu items
|
||||||
static const char pceTCMenuItem1[] PROGMEM = "Read ROM";
|
static const char pceTCMenuItem1[] PROGMEM = "Read ROM";
|
||||||
|
@ -528,8 +528,8 @@ void writeSRAM_SMS() {
|
|||||||
if (myFile.open(filePath, O_READ)) {
|
if (myFile.open(filePath, O_READ)) {
|
||||||
// Get SRAM size from file, with a maximum of 32KB
|
// Get SRAM size from file, with a maximum of 32KB
|
||||||
uint32_t sramSize = myFile.fileSize();
|
uint32_t sramSize = myFile.fileSize();
|
||||||
if (sramSize > (32 * 1024)) {
|
if (sramSize > ((uint32_t)32 * (uint32_t)1024)) {
|
||||||
sramSize = 32 * 1024;
|
sramSize = (uint32_t)32 * (uint32_t)1024;
|
||||||
}
|
}
|
||||||
print_Msg(F("sramSize: "));
|
print_Msg(F("sramSize: "));
|
||||||
print_Msg(sramSize);
|
print_Msg(sramSize);
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
int32_t readClockOffset() {
|
int32_t readClockOffset() {
|
||||||
FsFile clock_file;
|
FsFile clock_file;
|
||||||
unsigned char* clock_buf;
|
char* clock_buf;
|
||||||
int16_t i;
|
int16_t i;
|
||||||
int32_t clock_offset;
|
int32_t clock_offset;
|
||||||
|
|
||||||
@ -12,7 +12,7 @@ int32_t readClockOffset() {
|
|||||||
return INT32_MIN;
|
return INT32_MIN;
|
||||||
}
|
}
|
||||||
|
|
||||||
clock_buf = malloc(12 * sizeof(char));
|
clock_buf = (char*)malloc(12 * sizeof(char));
|
||||||
i = clock_file.read(clock_buf, 11);
|
i = clock_file.read(clock_buf, 11);
|
||||||
clock_file.close();
|
clock_file.close();
|
||||||
if (i == -1) {
|
if (i == -1) {
|
||||||
|
Loading…
Reference in New Issue
Block a user