From: pierre Date: Mon, 2 Feb 2015 21:49:36 +0000 (+0000) Subject: Fix for failures on FileNameCaseSensitive systems X-Git-Tag: archive/raspbian/3.0.4+dfsg-15+rpi1^2~4 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=f6ce2ed9962a465320e864bc24b5bda474bc8c3a;p=fpc.git Fix for failures on FileNameCaseSensitive systems git-svn-id: http://svn.freepascal.org/svn/fpc/trunk@29609 3ad0048d-3df7-0310-abae-a5850022a9f2 Gbp-Pq: Name fix_texpfncase_test.patch --- diff --git a/fpcsrc/tests/test/units/sysutils/texpfncase.pp b/fpcsrc/tests/test/units/sysutils/texpfncase.pp index 3a6e1cac..a4adf805 100644 --- a/fpcsrc/tests/test/units/sysutils/texpfncase.pp +++ b/fpcsrc/tests/test/units/sysutils/texpfncase.pp @@ -57,8 +57,9 @@ var Match: TFilenameCaseMatch; begin FN2 := ExpandFileNameCase (FN1, Match); - if ((ExpReturn <> '') and (FN2 <> ExpReturn) or (Match <> ExpMatch)) and - not(FileNameCaseSensitive and (Match=mkAmbiguous) and (UpperCase(FN2)<>UpperCase(ExpReturn))) then + if (Match <> ExpMatch) or ((ExpReturn <> '') and (FN2 <> ExpReturn) and + ((Match <> mkAmbiguous) or not (FileNameCaseSensitive) or + (UpperCase (FN2) <> UpperCase (ExpReturn)))) then begin Inc (Failed); WriteLn ('Error: Input = ', FN1, ', Output = ', FN2, ' (expected ', ExpReturn, '), MatchFound = ',