Fixed incorrect comparision introduced in `0ab27c674b7`.
Fixed incorrect comparision introduced in `0ab27c674b7`.

As written the code was comparing a `TaskState` against a
`v1::TaskState` which are different enums. This was not only brittle and
not guaranteed to work, but very likely also not intended.

This patch fixes the code to compare values of the same enum type.

Review: https://reviews.apache.org/r/70721

gsantovena/mesos,gsantovena/mesos,kaysoky/mesos,Gilbert88/mesos,gsantovena/mesos,kaysoky/mesos,abudnik/mesos,dforsyth/mesos,reneploetz/mesos,kaysoky/mesos,abudnik/mesos,abudnik/mesos,gsantovena/mesos,Gilbert88/mesos,dforsyth/mesos,chhsia0/mesos,reneploetz/mesos,reneploetz/mesos,chhsia0/mesos,abudnik/mesos,chhsia0/mesos,reneploetz/mesos,kaysoky/mesos,Gilbert88/mesos,abudnik/mesos,Gilbert88/mesos,gsantovena/mesos,abudnik/mesos,Gilbert88/mesos,chhsia0/mesos,dforsyth/mesos,reneploetz/mesos,chhsia0/mesos,kaysoky/mesos,abudnik/mesos,chhsia0/mesos,Gilbert88/mesos,reneploetz/mesos,dforsyth/mesos,reneploetz/mesos,Gilbert88/mesos,kaysoky/mesos,dforsyth/mesos,kaysoky/mesos,dforsyth/mesos,gsantovena/mesos,chhsia0/mesos,dforsyth/mesos,gsantovena/mesos