Various fixes in telldusd