LINK_OPTIONS: Fix crash on empty LINKER: prefix

Since commit e3895f4a8b (Linking: Preserve nested LINKER: prefixes as
written, 2024-09-17, v3.31.0-rc1~60^2) we may increment an iterator past
the end.  Revise logic to avoid that.

Fixes: #26499
2 files changed