Unexport factory functions

This commit is contained in:
2025-10-21 22:37:10 +02:00
parent 2b51b4a47f
commit bac18b5626
6 changed files with 15 additions and 15 deletions

View File

@@ -23,9 +23,9 @@ type portAllocator struct {
rangeSize int
}
// NewPortAllocator creates a new port allocator for the given port range.
// newPortAllocator creates a new port allocator for the given port range.
// Returns an error if the port range is invalid.
func NewPortAllocator(minPort, maxPort int) (*portAllocator, error) {
func newPortAllocator(minPort, maxPort int) (*portAllocator, error) {
if minPort <= 0 || maxPort <= 0 {
return nil, fmt.Errorf("invalid port range: min=%d, max=%d (must be > 0)", minPort, maxPort)
}