mirror of
				https://github.com/cloudreve/cloudreve.git
				synced 2025-10-31 08:39:10 +08:00 
			
		
		
		
	Fix: stop listening HTTP port if unix socket is enabled (#729)
This commit is contained in:
		
							
								
								
									
										2
									
								
								assets
									
									
									
									
									
								
							
							
								
								
								
								
								
							
						
						
									
										2
									
								
								assets
									
									
									
									
									
								
							 Submodule assets updated: 8a3553aec3...21c3082ba8
									
								
							
							
								
								
									
										11
									
								
								main.go
									
									
									
									
									
								
							
							
						
						
									
										11
									
								
								main.go
									
									
									
									
									
								
							| @ -51,12 +51,11 @@ func main() { | |||||||
|  |  | ||||||
| 	// 如果启用了Unix | 	// 如果启用了Unix | ||||||
| 	if conf.UnixConfig.Listen != "" { | 	if conf.UnixConfig.Listen != "" { | ||||||
| 		go func() { | 		util.Log().Info("开始监听 %s", conf.UnixConfig.Listen) | ||||||
| 			util.Log().Info("开始监听 %s", conf.UnixConfig.Listen) | 		if err := api.RunUnix(conf.UnixConfig.Listen); err != nil { | ||||||
| 			if err := api.RunUnix(conf.UnixConfig.Listen); err != nil { | 			util.Log().Error("无法监听[%s],%s", conf.UnixConfig.Listen, err) | ||||||
| 				util.Log().Error("无法监听[%s],%s", conf.UnixConfig.Listen, err) | 		} | ||||||
| 			} | 		return | ||||||
| 		}() |  | ||||||
| 	} | 	} | ||||||
|  |  | ||||||
| 	util.Log().Info("开始监听 %s", conf.SystemConfig.Listen) | 	util.Log().Info("开始监听 %s", conf.SystemConfig.Listen) | ||||||
|  | |||||||
		Reference in New Issue
	
	Block a user
	 HFO4
					HFO4