mirror of
https://github.com/Michaelangel007/apple2_prodos_utils.git
synced 2024-11-26 21:49:37 +00:00
Cleanup getHexVal()
This commit is contained in:
parent
ec5681f79e
commit
fe10d81843
13
prodos.cpp
13
prodos.cpp
@ -326,7 +326,7 @@ printf( "ERROR: Create Time not yet implemented\n" );
|
|||||||
|
|
||||||
if( pVal[0] == '$' )
|
if( pVal[0] == '$' )
|
||||||
{
|
{
|
||||||
val = getHexVal( pVal + 1 );
|
val = getHexVal( pVal ); // safely ignores leading $
|
||||||
if( val < 0x00 ) val = 0x00;
|
if( val < 0x00 ) val = 0x00;
|
||||||
if( val > 0xFF ) val = 0xFF;
|
if( val > 0xFF ) val = 0xFF;
|
||||||
entry->type = val;
|
entry->type = val;
|
||||||
@ -352,10 +352,13 @@ printf( "ERROR: Create Time not yet implemented\n" );
|
|||||||
nLenSuffix = nLenPrefix - 4;
|
nLenSuffix = nLenPrefix - 4;
|
||||||
pVal = arg + 4;
|
pVal = arg + 4;
|
||||||
|
|
||||||
val = getHexVal( pVal );
|
if( pVal[0] == '$' )
|
||||||
if( val < 0x0000 ) val = 0x0000;
|
{
|
||||||
if( val > 0xFFFF ) val = 0xFFFF;
|
val = getHexVal( pVal ); // safely ignores leading $
|
||||||
entry->aux = val;
|
if( val < 0x0000 ) val = 0x0000;
|
||||||
|
if( val > 0xFFFF ) val = 0xFFFF;
|
||||||
|
entry->aux = val;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
if( strncmp( arg, "access=", 7 ) == 0 )
|
if( strncmp( arg, "access=", 7 ) == 0 )
|
||||||
|
Loading…
Reference in New Issue
Block a user