'\" t .\" Title: ll2_import_lastlogg .\" Author: [see the "AUTHOR(S)" section] .\" Generator: Asciidoctor 2.0.26 .\" Date: 2026-05-18 .\" Manual: Programmerarens handbok .\" Source: util-linux 2.42.1 .\" Language: English .\" .TH "LL2_IMPORT_LASTLOG" "3" "2026-05-18" "util\-linux 2.42.1" "Programmerarens handbok" .ie \n(.g .ds Aq \(aq .el .ds Aq ' .ss \n[.ss] 0 .nh .ad l .de URL \fI\\$2\fP <\\$1>\\$3 .. .als MTO URL .if \n[.g] \{\ . mso www.tmac . am URL . ad l . . . am MTO . ad l . . . LINKSTYLE blue R < > .\} .SH "NAMN" ll2_import_lastlog \- Importerar gammal lastlog\-fil. .SH "SYNOPSIS" .sp \fB#include \fP .sp \fBint ll2_import_lastlog (struct ll2_context *\fIkontext\fP, const char *\fIlastlog_file\fP, char **\fIerror\fP);\fP .SH "BESKRIVNING" .sp Imports all entries from \fIlastlog_file\fP file (\fBlastlog\fP(8)) into lastlog2 database defined with \fIcontext\fP. If \fIcontext\fP is NULL, the default database, defined in \fILL2_DEFAULT_DATABASE\fP, will be taken. .sp .if n .RS 4 .nf .fam C char\& *error = NULL; const\& char *lastlog_path = "/var/log/lastlog"; int ret = ll2_import_lastlog (NULL, lastlog_path, &error); .fam .fi .if n .RE .SH "RETURVÄRDE" .sp Returnerar 0 vid framgång, \-ENOMEM eller \-1 vid annat misslyckande. \fIerror\fP innehåller en felsträng om returvärdet är \-1. det är inte garanterat att \fIerror\fP innehåller en felsträng, den kan också vara NULL. \fIerror\fP bör frigöras av den som anropar. .SH "UPPHOVSPERSONER" .sp .MTO "kukuk\(atsuse.de" "Thorsten Kukuk" "" .SH "SE ÄVEN" .sp \fBlastlog2\fP(3), \fBll2_new_context\fP(3), \fBll2_unref_context\fP(3), \fBll2_read_all\fP(3), \fBll2_write_entry\fP(3), \fBll2_read_entry\fP(3), \fBll2_update_login_time\fP(3), \fBll2_rename_user\fP(3), \fBll2_remove_entry\fP(3) .SH "FELRAPPORTERING" .sp För felrapporter, använd \c .URL "https://github.com/util\-linux/util\-linux/issues" "felhanteraren" "." .SH "TILLGÄNGLIGHET" .sp Biblioteket \fBliblastlog2\fP är en del av paketet util\-linux sedan version 2.40. Det kan laddas ner från \c .URL "https://www.kernel.org/pub/linux/utils/util\-linux/" "Linux Kernel Archive" "."