mirror of
https://git.codelinaro.org/clo/qsdk/oss/boot/u-boot-2016.git
synced 2025-12-10 07:44:53 +01:00
Merge "ipq40xx: Replace strcpy with strlcpy"
This commit is contained in:
commit
ed7b3de7eb
2 changed files with 3 additions and 2 deletions
|
|
@ -136,7 +136,8 @@ static void setup_commandline_tag(bd_t *bd, char *commandline)
|
|||
params->hdr.size =
|
||||
(sizeof (struct tag_header) + strlen (p) + 1 + 4) >> 2;
|
||||
|
||||
strcpy (params->u.cmdline.cmdline, p);
|
||||
strlcpy (params->u.cmdline.cmdline, p,
|
||||
sizeof(params->u.cmdline.cmdline));
|
||||
|
||||
params = tag_next (params);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -849,7 +849,7 @@ int ipq_gmac_init(ipq_gmac_board_cfg_t *gmac_cfg)
|
|||
|
||||
ipq_gmac_mii_clk_init(ipq_gmac_macs[i], clk_div_val, gmac_cfg);
|
||||
|
||||
strncpy((char *)ipq_gmac_macs[i]->phy_name, gmac_cfg->phy_name,
|
||||
strlcpy((char *)ipq_gmac_macs[i]->phy_name, gmac_cfg->phy_name,
|
||||
sizeof(ipq_gmac_macs[i]->phy_name));
|
||||
bb_nodes[i] = malloc(sizeof(struct bitbang_nodes));
|
||||
if (bb_nodes[i] == NULL)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue