Browse Source

fix: don't print usage on port allocation error

When a port allocation fails (e.g., explicit port is unavailable), exit
immediately without showing the usage example. This provides cleaner
error output when the error is expected (port conflict).
pull/7838/head
Chris Lu 2 months ago
parent
commit
c5af6a82c7
  1. 2
      weed/command/mini.go

2
weed/command/mini.go

@ -706,7 +706,7 @@ func runMini(cmd *Command, args []string) bool {
// Ensure all ports are available, find alternatives if needed
if err := ensureAllPortsAvailableOnIP(bindIp); err != nil {
glog.Errorf("Port allocation failed: %v", err)
return false
os.Exit(1)
}
// Set master.peers to "none" if not specified (single master mode)

Loading…
Cancel
Save