Fix sanitizing filenames

Signed-off-by: Alexandre Peixoto Ferreira <alexandref75@gmail.com>
This commit is contained in:
Alexandre Peixoto Ferreira 2022-07-18 12:45:02 -05:00
parent e20fb9b58f
commit fe9b26d283
No known key found for this signature in database
GPG Key ID: 9BDC9DE410CFC23B

View File

@ -93,7 +93,7 @@ func readDevDirectory(dirToList string, allowedRecursions uint8) (files []string
} }
func sanitizeName(path string) string { func sanitizeName(path string) string {
return strings.Replace(path, "/", "_" ,-1) return strings.Replace(path, "/!@#$%^&*()[]{}'`~.", "___________________",-1)
} }
func findDevicesPattern(listDevices []string, pattern string) ([]string,error) { func findDevicesPattern(listDevices []string, pattern string) ([]string,error) {