src/windows/native/java/io/canonicalize_md.c
static char *
cp(char *dst, char *dend, char first, char *src, char *send)
{
    char *p = src, *q = dst;
    if (first != '\0') {
        if (q < dend) {
            *q++ = first;
        } else {
            errno = ENAMETOOLONG;
            return NULL;
        }
    }
    if (send - p > dend - q) {
        errno = ENAMETOOLONG;
        return NULL;
    }
    while (p < send) {
        *q++ = *p++;
    }
    return q;
}
/* Copy bytes to dst, not going past dend; return dst + number of bytes copied,
   or NULL if dend would have been exceeded.  If first != '\0', copy that byte
   before copying bytes from src to send - 1. */
Copy bytes to dst, not going past dend; return dst + number of bytes copied,
or NULL if dend would have been exceeded.  If first != '\0', copy that byte
before copying bytes from src to send - 1.
Copy bytes to dst not going past dend ; return dst + number of bytes copied or NULL if dend would have been exceeded . If first ! = ' \ 0 ' copy that byte before copying bytes from src to send - 1 .
static char *
cp(char *dst, char *dend, char first, char *src, char *send)
{
    char *p = src, *q = dst;
    if (first != '\0') {
        if (q < dend) {
            *q++ = first;
        } else {
            errno = ENAMETOOLONG;
            return NULL;
        }
    }
    if (send - p > dend - q) {
        errno = ENAMETOOLONG;
        return NULL;
    }
    while (p < send) {
        *q++ = *p++;
    }
    return q;
}
static char * cp ( char * dst , char * dend , char first , char * src , char * send ) { char * p = src , * q = dst ; if ( first != ' \0 ' ) { if ( q < dend ) { * q ++ = first ; } else { errno = ENAMETOOLONG ; return NULL ; } } if ( send - p > dend - q ) { errno = ENAMETOOLONG ; return NULL ; } while ( p < send ) { * q ++ = * p ++ ; } return q ; }
Copy bytes to dst, not going past dend; return dst + number of bytes copied,
or NULL if dend would have been exceeded.
Copy bytes to dst not going past dend ; return dst + number of bytes copied or NULL if dend would have been exceeded .