lib/utmp.c: Fix use of last utmp entry instead of patrial-match entry
The pointer returned by getutxent() function may always point to
the same shared and reused buffer.
Instead of copying the utmp entry pointer value the content of utmp
entry must be copied otherwise the next call of getutxent() will
overwrite previously found entry.
This commit has no optimisations to highlight what is really fixed.