Re: [RFR] man://manpages-de/strcpy.3
Am 14.10.2012 14:19, schrieb Martin Eberhard Schauer:
Hier haben sich nach dem ersten Durchlauf vier Meldungen geändert.
Martin
#. https://lwn.net/Articles/506530/
#. type: Plain text
msgid ""
"This function is similar to B<strncpy>(), but it copies at most I<size-1> "
"bytes to I<dest>, always adds a terminating null byte, and does not pad
the "
"target with (further) null bytes. This function fixes some of the
problems "
"of B<strcpy>() and B<strncpy>(), but the caller must still handle the "
"possibility of data loss if I<size> is too small. The return value of
the "
"function is the length of I<src>, which allows truncation to be easily "
"detected: if the return value is greater than or equal to I<size>, "
"truncation occurred. If loss of data matters, the caller I<must> either "
"check the arguments before the call, or test the function return value. "
"B<strlcpy>() is not present in glibc and is not standardized by POSIX,
but "
"is available on Linux via the I<libbsd> library."
msgstr ""
"Diese Funktion ähnelt B<strncpy>(), aber sie kopiert höchstens
I<groesse-1> "
"Byte zum I<ziel>, fügt immer ein abschließendes Null-Byte hinzu und füllt "
"das Ziel nicht mit (weiteren) Null-Bytes auf. Diese Funktion behebt
einige "
"der Probleme von B<strcpy>() und B<strncpy>(), aber der Aufrufende muss
sich "
"mit der Möglichkeit von Datenverlust befassen, wenn I<groesse> zu klein
ist. "
"Der Rückgabewert der Funktion ist die Länge der I<quelle>, mit der die "
"Verkürzung leicht erkannt werden kann: wenn der Rückgabewert größer als
oder "
"gleich der I<groesse> ist, wurde verkürzt. Wenn Datenverlust nicht
auftreten "
"darf, I<muss> der Aufrufende entweder die Argumente vor dem Aufruf oder
den "
"Rückgabewert der Funktion prüfen. B<strlcpy>() ist nicht in der Glibc "
"vorhanden und nicht von POSIX standardisiert, sondern ist unter Linux
über "
"die Bibliothek I<libbsd> verfügbar."
s/I<groesse-1>/I<Größe-1>
s/I<ziel>/I<Ziel>
ebenso für groesse, quelle
Sonst sieht's gut aus.
Gruß,
Chris
Reply to: