sgpe: Proper handling of login failure

Would create an infinite loop
lcl[ent]: Proper handling of login failure