Here's a screenshot of derivation of Euler-Lagrange from feynman lecture https://www.feynmanlectures.caltech.edu/II_19.html
My doubt is in the last paragraph. I get that $\eta = 0$ at both ends, but we also have velocity $d\underline{x} / dt$ which is a function of $t$ and which may not be the same at the two points $t1$ and $t2$ to make the integrated term = 0. Can anybody kindly explain? I saw the same thing in Landau-Lifshitz as well.