2
0
mirror of https://github.com/acepanel/panel.git synced 2026-02-08 14:14:28 +08:00

fix(文件): 权限设置错误

This commit is contained in:
耗子
2024-06-24 22:20:41 +08:00
parent dfa14c3fd4
commit 09703761eb
3 changed files with 15 additions and 8 deletions

View File

@@ -487,7 +487,7 @@ func (r *MySQLController) getSock() string {
}
if io.Exists("/www/server/mysql/config/my.cnf") {
config, _ := io.Read("/www/server/mysql/config/my.cnf")
re := regexp.MustCompile(`socket\s*=\s*(['"]?)([^'"]+)\1`)
re := regexp.MustCompile(`socket\s*=\s*(['"]?)([^'"]+)`)
matches := re.FindStringSubmatch(config)
if len(matches) > 2 {
return matches[2]
@@ -495,7 +495,7 @@ func (r *MySQLController) getSock() string {
}
if io.Exists("/etc/my.cnf") {
config, _ := io.Read("/etc/my.cnf")
re := regexp.MustCompile(`socket\s*=\s*(['"]?)([^'"]+)\1`)
re := regexp.MustCompile(`socket\s*=\s*(['"]?)([^'"]+)`)
matches := re.FindStringSubmatch(config)
if len(matches) > 2 {
return matches[2]