PxStrncpy()

Copy a string with fixed length.

APPLIES TO

8.2.0

SYNOPSIS
PxChar_t* PxStrncpy(char *d, char const *s, PxSize_t n);
ARGUMENTS
d

Address to copy the string to

s

Address to copy the string from

n

Maximal count of characters in strings to copy

RETURN VALUES
  • Pointer to destination string

DESCRIPTION

PxStrncpy copies at most "n" characters. If "s" has more than "n" characters, it is truncated to that length and the result is not null terminated.

USAGE
#include "pxdef.h"

PxStrncpy(d, s, len);