Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\string.c Create Date:2022-07-28 06:00:35
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:strscpy_pad() - Copy a C-string into a sized buffer*@dest: Where to copy the string to*@src: Where to copy the string from*@count: Size of destination buffer* Copy the string, or as much of it as fits, into the dest buffer. The

Proto:ssize_t strscpy_pad(char *dest, const char *src, size_t count)

Type:ssize_t

Parameter:

TypeParameterName
char *dest
const char *src
size_tcount
265  written = strscpy - Copy a C-string into a sized buffer*@dest: Where to copy the string to*@src: Where to copy the string from*@count: Size of destination buffer* Copy the string, or as much of it as fits, into the dest buffer. The
266  If written < 0 || written == count - 1 Then Return written
269  memset(dest + written + 1, 0, count - written - 1)
271  Return written
Caller
NameDescribe
tc() - Run a specific test case.*@src: Source string, argument to strscpy_pad()*@count: Size of destination buffer, argument to strscpy_pad()*@expected: Expected return value from call to strscpy_pad()