mirror of
https://github.com/doublecmd/doublecmd.git
synced 2026-06-21 09:58:13 +00:00
FIX: Don't allow a control codes in the file names under Windows (fixes #2285)
This commit is contained in:
parent
e73b33791b
commit
f8d7513354
1 changed files with 3 additions and 3 deletions
|
|
@ -3,7 +3,7 @@
|
|||
-------------------------------------------------------------------------
|
||||
Useful functions dealing with strings.
|
||||
|
||||
Copyright (C) 2006-2023 Alexander Koblov (alexx2000@mail.ru)
|
||||
Copyright (C) 2006-2025 Alexander Koblov (alexx2000@mail.ru)
|
||||
Copyright (C) 2012 Przemyslaw Nagay (cobines@gmail.com)
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
|
|
@ -650,7 +650,7 @@ end;
|
|||
function ReplaceInvalidChars(const FileName: String): String;
|
||||
const
|
||||
{$IFDEF MSWINDOWS}
|
||||
ForbiddenChars : set of char = ['<','>',':','"','/','|','?','*'];
|
||||
ForbiddenChars : set of char = [#00..#31, '<','>',':','"','/','|','?','*'];
|
||||
{$ELSE}
|
||||
ForbiddenChars : set of char = [#0];
|
||||
{$ENDIF}
|
||||
|
|
@ -671,7 +671,7 @@ end;
|
|||
function RemoveInvalidCharsFromFileName(const FileName: String): String;
|
||||
const
|
||||
{$IFDEF MSWINDOWS}
|
||||
ForbiddenChars : set of char = ['<','>',':','"','/','\','|','?','*'];
|
||||
ForbiddenChars : set of char = [#00..#31, '<','>',':','"','/','\','|','?','*'];
|
||||
{$ELSE}
|
||||
ForbiddenChars : set of char = ['/'];
|
||||
{$ENDIF}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue