mirror of
https://git.code.sf.net/p/newrpl/sources
synced 2024-11-16 19:51:25 +01:00
Sanity check bug fixes and improvements.
This commit is contained in:
parent
ea56c40062
commit
c7e6a6c584
4 changed files with 7 additions and 3 deletions
|
@ -160,6 +160,7 @@ const int keyMap[] = {
|
|||
Qt::Key_Backspace, 1,
|
||||
Qt::Key_U, 2,
|
||||
Qt::Key_Slash, 3,
|
||||
Qt::Key_Z, 3,
|
||||
Qt::Key_Asterisk, 4,
|
||||
Qt::Key_Minus, 5,
|
||||
Qt::Key_Plus, 6,
|
||||
|
|
|
@ -97,11 +97,14 @@ SOURCES +=\
|
|||
newrpl/lib-twenty-lam.c \
|
||||
newrpl/lib-two-ident.c \
|
||||
newrpl/lists.c \
|
||||
newrpl/matrix.c \
|
||||
newrpl/returnstack.c \
|
||||
newrpl/romlibs.c \
|
||||
newrpl/runstream.c \
|
||||
newrpl/symbolic.c \
|
||||
newrpl/tempob.c \
|
||||
newrpl/backup.c \
|
||||
newrpl/sanity.c \
|
||||
firmware/ui_cmdline.c \
|
||||
newrpl/lib-48-matrix.c \
|
||||
newrpl/utf8lib.c \
|
||||
|
@ -109,7 +112,6 @@ SOURCES +=\
|
|||
firmware/sys/Font6A.c \
|
||||
firmware/sys/Font5C.c \
|
||||
firmware/sys/Font7A.c \
|
||||
newrpl/matrix.c \
|
||||
firmware/sys/Font8C.c \
|
||||
firmware/sys/Font8D.c
|
||||
|
||||
|
|
|
@ -1322,7 +1322,7 @@ void LIB_HANDLER()
|
|||
if(!usedbytes) { RetNum=ERR_INVALID; return; } // IDENT HAS AN EXTRA WORD
|
||||
|
||||
// AND CHECK FOR NAME VALIDITY
|
||||
if(!rplIsValidIdent((BYTEPTR)(ObjectPTR+1),((BYTEPTR)ObjectPTR)+((len-1)<<2)+usedbytes)) { RetNum=ERR_INVALID; return; }
|
||||
if(!rplIsValidIdent((BYTEPTR)(ObjectPTR+1),((BYTEPTR)ObjectPTR)+(len<<2)+usedbytes)) { RetNum=ERR_INVALID; return; }
|
||||
}
|
||||
RetNum=OK_CONTINUE;
|
||||
return;
|
||||
|
|
|
@ -445,9 +445,10 @@ else {
|
|||
// IF CONTENTS ARE A DIRECTORY HANDLE, CHECK IF THE HANDLE IS VALID
|
||||
|
||||
if(ISDIR(*dirptr[1])) {
|
||||
if(!rplFindDirbyHandle(*dirptr[1])) {
|
||||
if(!rplFindDirbyHandle(dirptr[1])) {
|
||||
// THIS IS AN INVALID ENTRY TO A NON-EXISTENT OR CORRUPTED DIRECTORY OBJECT
|
||||
// JUST PURGE IT
|
||||
if(!fix) return 0;
|
||||
rplPurgeForced(dirptr);
|
||||
continue;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue