prevent crash when remote name is short

Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com>