Also Posix specifically says that there are 86400 seconds in a day, every day, without exception. It allows for the time 23:59:60 by saying that the time in seconds is /approximately/ the time since midnight at the start of 1970 …
It’s a mess, but it’s a well-intentioned mess. t + 86400 is this time tomorrow. For those few people who are prepared to do arithmetic “properly” (tomorrow might be t + 86399 or t + 86401) the timezone files including leap seconds are available. That’s not a posix system though … you pays your money, you takes your choice.
jch