kubernetes/pkg/util/flag
S. M. Mohiuddin Khan Shiam e7d76f37a4 flag: fix nil-ptr panic & typo messages
### What changed
* [RegisterWithTaintsVar](cci:2://file:///d:/Github/kubernetes/pkg/util/flag/flags.go:260:0-262:1)
  * Added nil-target checks in [Set](cci:1://file:///d:/Github/kubernetes/pkg/util/flag/flags.go:170:0-231:1) and [String](cci:1://file:///d:/Github/kubernetes/pkg/util/flag/flags.go:151:0-157:1); avoids panic when slice pointer isn’t pre-initialised.
* [ReservedMemoryVar](cci:2://file:///d:/Github/kubernetes/pkg/util/flag/flags.go:165:0-168:1)
  * Closed missing parenthesis in error string.
  * Corrected spelling in three user-visible error messages.

### Why it matters
* Prevents kubelet (and any consumer) from crashing during flag parsing if the `--register-with-taints` target slice wasn’t set up.
* Clear, correctly-spelled errors make mis-configured `--reserved-memory` flags easier to diagnose.

_No functional behaviour altered; only robustness and usability improved._
2025-06-18 02:06:11 +06:00
..
flags.go flag: fix nil-ptr panic & typo messages 2025-06-18 02:06:11 +06:00
flags_test.go ReservedMemory Configuration for NUMA 2021-12-14 16:15:23 +05:30