mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2026-03-29 07:57:59 -04:00
add snd_strlcpy() and use it everywhere
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
parent
639d404df6
commit
1755df1d9e
14 changed files with 74 additions and 61 deletions
|
|
@ -282,15 +282,6 @@ struct tplg_elem *tplg_elem_lookup(struct list_head *base,
|
|||
struct tplg_elem* tplg_elem_new_common(snd_tplg_t *tplg,
|
||||
snd_config_t *cfg, const char *name, enum snd_tplg_type type);
|
||||
|
||||
static inline void elem_copy_text(char *dest, const char *src, int len)
|
||||
{
|
||||
if (!dest || !src || !len)
|
||||
return;
|
||||
|
||||
strncpy(dest, src, len);
|
||||
dest[len - 1] = 0;
|
||||
}
|
||||
|
||||
int tplg_parse_channel(snd_tplg_t *tplg ATTRIBUTE_UNUSED,
|
||||
snd_config_t *cfg, void *private);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue