added tft tests
fixed warnings in tft.c and tft.h