make TTL work

fixes #1068 

It lacks tests, but is able to work well.
i wanna get some feedback for this implementation, and I am adding tests for it now.
i will clean it up. the new `softstate` has to be pointer, since we need to know if it is set or unset... as the boolp. There is no magic field in `softstate`.