@joebigelow / wix-1 / commits / 035eccfb

File and folder names that start with dots are not valid short names

Fixes 7313

Rob Mensching committed Mar 24, 2023 at 11:43 UTC 035eccfb7400a8e6099e239b2b39116d95ddfb9f
3 files changed +3 -1
src/wix/WixToolset.Core/Common.cs
+1 -1
@@ -249,7 +249,7 @@ namespace WixToolset.Core
249 {
250 return filename.Length < 9;
251 }
252 - else if (expectedDot > 8 || filename[expectedDot] != '.' || expectedDot + 4 < filename.Length)
252 + else if (expectedDot == 0 || expectedDot > 8 || filename[expectedDot] != '.' || expectedDot + 4 < filename.Length)
253 {
254 return false;
255 }
src/wix/test/WixToolsetTest.CoreIntegration/MsiQueryFixture.cs
+1
@@ -282,6 +282,7 @@ namespace WixToolsetTest.CoreIntegration
282 "Directory:Folder12\tINSTALLFOLDER\tFolder.12",
283 "Directory:Folder123\tINSTALLFOLDER\tFolder.123",
284 "Directory:Folder1234\tINSTALLFOLDER\tyakwclwy|Folder.1234",
285 + "Directory:GitFolder\tINSTALLFOLDER\t69sdfw2d|.git",
286 "Directory:INSTALLFOLDER\tProgramFiles6432Folder\t1egc1laj|MsiPackage",
287 "Directory:NAMEANDSHORTNAME\tINSTALLFOLDER\tSHORTNAM|NameAndShortName",
288 "Directory:NAMEANDSHORTSOURCENAME\tINSTALLFOLDER\tNAMEASSN|NameAndShortSourceName",
src/wix/test/WixToolsetTest.CoreIntegration/TestData/DefaultDir/DefaultDir.wxs
+1
@@ -21,6 +21,7 @@
21 <Directory Id="Folder12" Name="Folder.12"></Directory>
22 <Directory Id="Folder123" Name="Folder.123"></Directory>
23 <Directory Id="Folder1234" Name="Folder.1234"></Directory>
24 + <Directory Id="GitFolder" Name=".git"></Directory>
25 </DirectoryRef>
26 </Fragment>
27 </Wix>