Merge pull request #4095 from pacovn/201904_master__lm_aliasing_fixes

zebra: label manager race condition fix
This commit is contained in:
Donald Sharp 2019-04-09 08:38:02 -04:00 committed by GitHub
commit 977e9f3791
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -156,11 +156,9 @@ static int lm_zclient_read(struct thread *t)
/* read response and send it back */
ret = relay_response_back();
/* on error, schedule another read */
if (ret == -1)
if (!zclient->t_read)
thread_add_read(zclient->master, lm_zclient_read, NULL,
zclient->sock, &zclient->t_read);
/* re-arm read */
thread_add_read(zclient->master, lm_zclient_read, NULL,
zclient->sock, &zclient->t_read);
return ret;
}