Lebesgue integration in $\mathbb{R}^{n}$: Folland 2.56 I am trying to solve this question in Folland's Real Analysis: Modern Techniques and Their Applications, but cannot get anywhere with it:

If $f$ is Lebesgue integrable on $(0,a)$ and $g(x) = \int_{x}^{a}
 t^{-1} f(t) \, \mathrm{d} t$, then $g$ is lebesgue integrable on
  $(0,a)$ and $\int_{0}^{a} g(t) \, \mathrm{d} t = \int_{0}^{a} f(t) \, \mathrm{d} t$.

All I have been able to get to show that $g$ is integrable is:
\begin{align} \int_{(0, a)} |g(x)| \, \mathrm{d} m(x) &= \int_{(0, a)} \left| \int_{(x,a)} t^{-1} f(t) \, \mathrm{d} m(t) \right| \, \mathrm{d} m(x)\\
&\leq \int_{(0, a)}  \int_{(x,a)} \left| t^{-1} f(t)\right| \, \mathrm{d} m(t)  \, \mathrm{d} m(x)\end{align}
And I do not know how to show that $\int_{0}^{a} g(t) \, \mathrm{d} t = \int_{0}^{a} f(t) \, \mathrm{d} t$. Any help is appreciated.
 A: Hint:
$$g(x) = \int_0^a \chi_{[x,a]}(t)t^{-1}f(t)\,dt$$
and so
$$\int_0^a |g(x)| = \int_0^a\left|\int_0^a \chi_{[x,a]}(t)t^{-1}f(t)\,dt\right|\,dx \le \int_0^a\int_0^a \chi_{[x,a]}(t)t^{-1}|f(t)|\,dt\,dx.$$
Interchange integrals by Tonelli:
$$\int_0^a\left(\int_0^a \chi_{[x,a]}(t)\,dx\right) t^{-1}|f(t)|\,dt.$$
$$\chi_{[x,a]}(t) = \begin{cases} 1 & t\in[x,a] \\ 0 & t\not\in[x,a]\end{cases}.$$
Note that if $t\in[x,a]$, then $x\le t\le a$ and so $x\le t$. Likewise, if $t\not\in [x,a]$, then $0 \le t < x$. This gives that $\chi_{[x,a]}(t) = \chi_{[0,t]}(x)$.
After using the above to argue integrability, apply Fubini-Tonelli.
A: As you know $\int_0^ag(x)\,dx = \int_0^a\int_x^at^{-1}f(t)\,dt\,dx$ (here I am using $dt$ and $dx$ as a shorthand for the Lebesgue measure). Notice that the domain of integration on the RHS is a triangle in the $t$-$x$ plane: $$T = \{(t,x): 0 \le x \le a,\ x \le t\le a\}.$$ This can be rewritten as $$T = \{(t,x): 0 \le t \le a,\ 0 \le x \le t\}.$$ Hence by Fubini's theorem we get $$\int_0^ag(x)\,dx = \int_0^a\int_0^tt^{-1}f(t)\,dx\,dt = \int_0^at^{-1}f(t)\int_0^t\,dx\,dt = \int_0^af(t)\,dt.$$
