TSAGE: Fix GCC warning about possibly undefined behaviour