mirror of
https://github.com/containers/podman.git
synced 2026-10-24 02:39:13 -04:00
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
11 lines
249 B
Go
11 lines
249 B
Go
package internal
|
|
|
|
// CheckRequestedWidth checks that requested width doesn't overflow
|
|
// available width
|
|
func CheckRequestedWidth(requested, available int) int {
|
|
if requested < 1 || requested > available {
|
|
return available
|
|
}
|
|
return requested
|
|
}
|