Changeset 4426855 in rtems


Ignore:
Timestamp:
Apr 15, 2003, 2:58:28 PM (17 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Children:
e3aa7c1
Parents:
eedf195
Message:

2003-04-15 Joel Sherrill <joel@…>

PR 388/networking

  • kern/kern_sysctl.c: Revert previous patch and use strlcpy() now that it is available. Also fixed some warnings.
Location:
cpukit/libnetworking
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • cpukit/libnetworking/ChangeLog

    reedf195 r4426855  
     12003-04-15      Joel Sherrill <joel@OARcorp.com>
     2
     3        PR 388/networking
     4        * kern/kern_sysctl.c: Revert previous patch and use strlcpy() now that
     5        it is available. Also fixed some warnings.
     6
    172003-03-27      Joel Sherrill <joel@OARcorp.com>
    28
  • cpukit/libnetworking/kern/kern_sysctl.c

    reedf195 r4426855  
    6060#else
    6161#include <sys/buf.h>
     62
     63#include <stdio.h>                                /* for snprintf() */
     64size_t   strlcpy(char *, const char *, size_t);
    6265#endif
    6366#include <vm/vm.h>
     
    857860        tmparg = malloc(outlen, M_SYSCTLTMP, M_WAITOK);
    858861
    859         if (strncpy(tmparg, (char *)arg1, outlen) >= outlen) {
     862        if (strlcpy(tmparg, (char *)arg1, outlen) >= outlen) {
    860863                free(tmparg, M_SYSCTLTMP);
    861864                goto retry;
Note: See TracChangeset for help on using the changeset viewer.