Supersymmetric Localization (Mirror Symmetry) I'm reading Chapter 9 of Mirror Symmetry book. As you can see in eq. (9.30) his model for SUSY is
$$\begin{align}
\delta_\epsilon X &=\epsilon^1\psi_1 + \epsilon^2\psi_2\\
\delta\psi_1 &= \epsilon^2\partial h\\
\delta\psi_2 &=-\epsilon^1\partial h. 
\end{align}\tag{9.30}$$
I understand that if $\partial h\neq 0$ it is possible to see that partition function vanishes, in particular, there is a total divergence:
$$
\int \mathrm{d}\hat{X}e^{\frac{1}{2}(\partial h(\hat{X}))^2}\frac{\partial^2 h(\hat{X})}{(\partial h(\hat{X}))^2}.
\tag{*}
$$
The implication that a total divergence yields vanishing integral, it is a bit strange, because, since every function that admit a primitive is a total derivative. What is the meaning of that implication? Then why $(*)$ vanishes? It seems to me that, in general,
$$
\int \mathrm{d}(h')\frac{e^{\frac{1}{2}(h')^2}}{(h')^2}\neq 0.
$$
Then, again, when he claims that if there is a $x_0$ such that $h'(x_0)=0$ we can use again the argument of the total divergence, why doesn't he keep in account that, removing a small neighborhood of $x_0$, give us some contribution at the border of that neighborhood (two points)?
 A: *

*OP essentially wrote (v2): 

The implication that a total divergence $f=F^{\prime}$ yields vanishing integral $\int_{\mathbb{R}} \! dx ~f(x)=0$ is a bit strange, because, since every function $f$ that admit a primitive $F$ is a total derivative $f=F^{\prime}$.

Answer: Well, the devil is in the detail. Ref. 1 starts with a function $F$ that is assumed$^1$ to vanishes at $x=\pm \infty$:
$$ F(x\!=\!\pm \infty)~=~0. \tag{A}$$
If we, on the other hand, instead start from a function $f$, then all its primitives $F$ will generically not satisfy condition (A).

*OP essentially wrote (v2): 

Why doesn't Ref. 1 keep in account that, removing a small neighborhood of $x_0$, give us some contribution at the border of that neighborhood (two points)?

Answer: The neighborhood may be chosen as small as we want, thereby localizing the path integral $Z$ at the point $x_0$. 

*See also this related Phys.SE post.
References:


*

*K. Hori, S. Katz, A. Klemm, R. Pandharipande, R. Thomas, C. Vafa, R. Vakil, and E. Zaslow, Mirror Symmetry, 2003; Sections 9.2-9.3. The pdf file is available here.


--
$^1$ Ref. 1 does not seem to explicitly mentioning assumption (A), but that is what is meant. Technically, it is sufficient if
$$ F(x\!=\!- \infty)~=~F(x\!=\! \infty). \tag{B}$$
