Fixed bug with ttl output