Skip to content

Commit b84382b

Browse files
authored
Merge pull request #437 from povik/fix-fF-unit
Fix capacitance unit parsing
2 parents 279217b + 3455f42 commit b84382b

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

src/map/scl/sclLiberty.c

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -941,11 +941,16 @@ void Scl_LibertyReadLoadUnit( Scl_Tree_t * p, Vec_Str_t * vOut )
941941
char * pHead = Scl_LibertyReadString(p, pItem->Head);
942942
float First = atof(strtok(pHead, " \t\n\r\\\","));
943943
char * pSecond = strtok(NULL, " \t\n\r\\\",");
944-
Vec_StrPutF_( vOut, First );
945-
if ( pSecond && !strcmp(pSecond, "pf") )
944+
if ( pSecond && (!strcmp(pSecond, "pf") || !strcmp(pSecond, "pF")) )
945+
{
946+
Vec_StrPutF_( vOut, First );
946947
Vec_StrPutI_( vOut, 12 );
947-
else if ( pSecond && !strcmp(pSecond, "ff") )
948+
}
949+
else if ( pSecond && (!strcmp(pSecond, "ff") || !strcmp(pSecond, "fF")) )
950+
{
951+
Vec_StrPutF_( vOut, First );
948952
Vec_StrPutI_( vOut, 15 );
953+
}
949954
else break;
950955
return;
951956
}

0 commit comments

Comments
 (0)