Bug 393011

Summary: Releaseme tries to create files with invalid names on Windows
Product: [Developer tools] releaseme Reporter: Hannah von Reth <vonreth>
Component: generalAssignee: Harald Sitter <sitter>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Microsoft Windows   
OS: Microsoft Windows   
Latest Commit: Version Fixed In:
Attachments: log

Description Hannah von Reth 2018-04-11 14:33:19 UTC
Created attachment 111956 [details]
log

ReleaseMe::L10n20180411-15208-o9l143
Comment 1 Harald Sitter 2018-10-25 12:34:59 UTC
Git commit 58268abecb3c842a3ec1c482f9fb58a6d0e403e4 by Harald Sitter.
Committed on 25/10/2018 at 12:34.
Pushed by sitter into branch 'master'.

override Dir#mktmpdir to force-sanitize prefix_suffix

on windows the allowed characters for directories is stricter than on posix
and as a result self.class may not be used as prefix verbatim.
as a safe guard we now prepend a sanitizer to Dir#mktmpdir so that only
valid characters can be used as prefix_suffix and we wont accidently create
invalid paths in the future

M  +1    -0    lib/releaseme.rb
C  +27   -22   lib/releaseme/tmpdir.rb [from: lib/releaseme.rb - 050% similarity]
M  +1    -0    lib/releaseme/translationunit.rb
A  +50   -0    test/tmpdir_test.rb

https://commits.kde.org/releaseme/58268abecb3c842a3ec1c482f9fb58a6d0e403e4