TSAGE: Fix CID 1088575, 1003719, 1003716  (3 real bugs)