Fix two bugs

This commit is contained in:
TuxSH 2017-05-23 21:47:20 +02:00
parent 68d9674ca3
commit 90b54581b0
2 changed files with 8 additions and 5 deletions

View File

@ -37,10 +37,13 @@ void main(int argc, char **argv)
fbs[1] = fbsrc[1]; fbs[1] = fbsrc[1];
} }
u32 i; if(argc >= 1)
for(i = 0; i < sizeof(absPath) - 1 && argv[0][i] != 0; i++) {
absPath[i] = argv[0][i]; u32 i;
absPath[i] = 0; for(i = 0; i < sizeof(absPath) - 1 && argv[0][i] != 0; i++)
absPath[i] = argv[0][i];
absPath[i] = 0;
}
char *argvPassed[2] = {absPath, (char *)&fbs}; char *argvPassed[2] = {absPath, (char *)&fbs};

View File

@ -44,7 +44,7 @@
static const u32 brightness[4] = {0x5F, 0x4C, 0x39, 0x26}; static const u32 brightness[4] = {0x5F, 0x4C, 0x39, 0x26};
static volatile Arm11Operation *operation = (volatile Arm11Operation *)0x1FFFFFF0; static volatile Arm11Operation *operation = (volatile Arm11Operation *)0x1FF80004;
struct fb fbs[2]; struct fb fbs[2];