#372 closed defect (fixed)

strlcpy

Reported by: Ralf Corsepius Owned by: Eric Norum
Priority: lowest Milestone: 2
Component: network/legacy Version: 4.6
Severity: normal Keywords:
Cc: bugs@…, joel.sherrill@… Blocked By:
Blocking:

Description

libnetworking uses the BSD-proprietary strlcpy:

../../../../../../../rtems-4-6-branch/cpukit/libnetworking/kern/kern_sysctl.c:859: warning: implicit declaration of function `strlcpy'

It would be more portable to apply the POSIX/BSD/SYSV compliant strncpy, instead and increase portability to other libc's but newlib.

By replacing strlcpy with strncpy we would avoid strlcpy completely and therefore would reduce the size of applications (eg. ca. 120Bytes on the arm).

Release:
RTEMS-4.6-branch + RTEMS-CVS

Change History (1)

comment:1 Changed on Mar 26, 2003 at 2:05:40 PM by Joel Sherrill

Status: assignedclosed

State-Changed-From-To: open->closed
State-Changed-Why: Patches applied to HEAD and 4.6 branch. Ralf removed

the offending implementations from pppd, added auto*
logic to conditionally have implementations in
cpukit/libcsupport, and fixed
cpukit/libnetworking/kern/kern_sysctl.c to not use
the offending routines.

Note: See TracTickets for help on using tickets.