OS Independence

This commit is contained in:
Pablu23
2023-12-11 12:21:23 +01:00
parent e19a9ba4f5
commit ce94fbbdd2

View File

@@ -242,7 +242,10 @@ func (server *Server) sendPTE(conn *net.UDPConn, addr *net.UDPAddr, pck *common.
file := filepath.Join(server.parentFilePath, path)
file = filepath.Clean(file)
matched, err := filepath.Match(fmt.Sprintf("%v\\*", server.parentFilePath), file)
// fmt.Sprintf("%v\\*", server.parentFilePath)
matched, err := filepath.Match(filepath.Join(server.parentFilePath, "*"), file)
fmt.Println(filepath.Join(server.parentFilePath, "*"))
if err != nil || !matched {
log.WithFields(log.Fields{