Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
To correct the calculations given by @Iván, the correct final result should be: $$ \frac{\sigma^2}{2\gamma^3}\left(2\gamma t + 2e^{-\gamma t}+2e^{-\gamma(t+\tau)}-e^{-\gamma \tau}-e^{-\gamma(2t+\tau)}-2 \right) $$