So, as you can see from my comments, the Session-Timeout attribute isn't present in the radius response debug from the first login. The second time when it appears, it is caluculated correctly. For now I think that I have an issue with FR, so I don't go further to my chillispot NAS yet. Do you have some suggestions?
It MIGHT be a bug, somewhat, in the default sql query in that it returns no integer if there's no previous accounting record. You can try running the query manually on a user which already logged in before and on new user.
If you can contribute a fix, please do. Maybe adding some IF/ELSE to the sql query?
Your suggestion worked. Also, commited the change on git repo. Thanks!
-- Fajar - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html