if (encrypt) {
#ifdef MUSTALIGN
if ((long) ivec & 3) {
- bcopy((char *)ivec++,(char *)&xor_0,sizeof(xor_0));
- bcopy((char *)ivec,(char *)&xor_1,sizeof(xor_1));
+ memcpy((char *)&xor_0, (char *)ivec++,sizeof(xor_0));
+ memcpy((char *)&xor_1, (char *)ivec, sizeof(xor_1));
}
else
#endif
/* get input */
#ifdef MUSTALIGN
if ((long) input & 3) {
- bcopy((char *)input,(char *)&t_input[0],sizeof(t_input[0]));
- bcopy((char *)(input+1),(char *)&t_input[1],sizeof(t_input[1]));
+ memcpy((char *)&t_input[0], (char *)input, sizeof(t_input[0]));
+ memcpy((char *)&t_input[1], (char *)(input+1),sizeof(t_input[1]));
}
else
#endif
*/
#ifdef MUSTALIGN
if ((long) input & 3) {
- bcopy((char *)input++,(char *)&xor_0,sizeof(xor_0));
+ memcpy((char *)&xor_0, (char *)input++, sizeof(xor_0));
xor_0 ^= t_output[0];
- bcopy((char *)input++,(char *)&xor_1,sizeof(xor_1));
+ memcpy((char *)&xor_1, (char *)input++, sizeof(xor_1));
xor_1 ^= t_output[1];
}
else
/* copy temp output and save it for cbc */
#ifdef MUSTALIGN
if ((long) output & 3) {
- bcopy((char *)&t_output[0],(char *)output++,
- sizeof(t_output[0]));
- bcopy((char *)&t_output[1],(char *)output++,
- sizeof(t_output[1]));
+ memcpy((char *)output++, (char *)&t_output[0],
+ sizeof(t_output[0]));
+ memcpy((char *)output++, (char *)&t_output[1],
+ sizeof(t_output[1]));
}
else
#endif
/* decrypt */
#ifdef MUSTALIGN
if ((long) ivec & 3) {
- bcopy((char *)ivec++,(char *)&xor_0,sizeof(xor_0));
- bcopy((char *)ivec,(char *)&xor_1,sizeof(xor_1));
+ memcpy((char *)&xor_0, (char *)ivec++,sizeof(xor_0));
+ memcpy((char *)&xor_1, (char *)ivec, sizeof(xor_1));
}
else
#endif
/* get input */
#ifdef MUSTALIGN
if ((long) input & 3) {
- bcopy((char *)input++,(char *)&t_input[0],sizeof(t_input[0]));
- bcopy((char *)input++,(char *)&t_input[1],sizeof(t_input[1]));
+ memcpy((char *)&t_input[0],(char *)input++,sizeof(t_input[0]));
+ memcpy((char *)&t_input[1],(char *)input++,sizeof(t_input[1]));
}
else
#endif
/* copy temp output */
#ifdef MUSTALIGN
if ((long) output & 3) {
- bcopy((char *)&t_output[0],(char *)output++,
- sizeof(t_output[0]));
- bcopy((char *)&t_output[1],(char *)output++,
- sizeof(t_output[1]));
+ memcpy((char *)output++, (char *)&t_output[0],
+ sizeof(t_output[0]));
+ memcpy((char *)output++, (char *)&t_output[1],
+ sizeof(t_output[1]));
}
else
#endif
}
retval[i]->ad_type = val->element_KRB5_2[i]->ad__type;
retval[i]->length = val->element_KRB5_2[i]->ad__data->qb_forw->qb_len;
- xbcopy(val->element_KRB5_2[i]->ad__data->qb_forw->qb_data,
- &retval[i]->contents[0], retval[i]->length);
+ memcpy(&retval[i]->contents[0],
+ val->element_KRB5_2[i]->ad__data->qb_forw->qb_data,
+ retval[i]->length);
}
retval[i] = 0;
return(retval);
}
retval[i]->ad_type = rv->element_KRB5_2->ad__type;
retval[i]->length = rv->element_KRB5_2->ad__data->qb_forw->qb_len;
- xbcopy(rv->element_KRB5_2->ad__data->qb_forw->qb_data,
- retval[i]->contents, retval[i]->length);
+ memcpy(retval[i]->contents,
+ rv->element_KRB5_2->ad__data->qb_forw->qb_data,
+ retval[i]->length);
}
retval[i] = 0;
return(retval);
}
retval[i]->addrtype = val->element_KRB5_0[i]->addr__type;
retval[i]->length = val->element_KRB5_0[i]->address->qb_forw->qb_len;
- xbcopy(val->element_KRB5_0[i]->address->qb_forw->qb_data,
- retval[i]->contents, retval[i]->length);
+ memcpy(retval[i]->contents,
+ val->element_KRB5_0[i]->address->qb_forw->qb_data,
+ retval[i]->length);
}
retval[i] = 0;
return(retval);
}
retval[i]->addrtype = rv->element_KRB5_0->addr__type;
retval[i]->length = rv->element_KRB5_0->address->qb_forw->qb_len;
- xbcopy(rv->element_KRB5_0->address->qb_forw->qb_data,
- retval[i]->contents, retval[i]->length);
+ memcpy(retval[i]->contents,
+ rv->element_KRB5_0->address->qb_forw->qb_data,
+ retval[i]->length);
}
retval[i] = 0;
return(retval);
}
retval->addrtype = val->addr__type;
retval->length = val->address->qb_forw->qb_len;
- xbcopy(val->address->qb_forw->qb_data,
- retval->contents, retval->length);
+ memcpy(retval->contents, val->address->qb_forw->qb_data, retval->length);
return(retval);
}
}
retval->checksum_type = val->cksumtype;
retval->length = val->checksum->qb_forw->qb_len;
- xbcopy(val->checksum->qb_forw->qb_data, retval->contents,
- val->checksum->qb_forw->qb_len);
+ memcpy(retval->contents, val->checksum->qb_forw->qb_data,
+ val->checksum->qb_forw->qb_len);
return(retval);
}
}
retval->keytype = val->keytype;
retval->length = val->keyvalue->qb_forw->qb_len;
- xbcopy(val->keyvalue->qb_forw->qb_data, retval->contents,
- val->keyvalue->qb_forw->qb_len);
+ memcpy(retval->contents, val->keyvalue->qb_forw->qb_data,
+ val->keyvalue->qb_forw->qb_len);
return(retval);
}
*error = ENOMEM;
return(0);
}
- xbcopy(rv->PA__DATA->pa__data->qb_forw->qb_data,
- retval[i]->contents, retval[i]->length);
+ memcpy(retval[i]->contents,
+ rv->PA__DATA->pa__data->qb_forw->qb_data,
+ retval[i]->length);
} else
retval[i]->contents = 0;
}
krb5_xfree(retval);
goto nomem;
}
- xbcopy(val->qb_forw->qb_data, retval->data,
- val->qb_forw->qb_len);
+ memcpy(retval->data, val->qb_forw->qb_data,
+ val->qb_forw->qb_len);
return(retval);
}
*error = ENOMEM;
return(0);
}
- xbcopy(rv->PA__DATA->pa__data->qb_forw->qb_data,
- retval[i]->contents, retval[i]->length);
+ memcpy(retval[i]->contents,
+ rv->PA__DATA->pa__data->qb_forw->qb_data,
+ retval[i]->length);
}
}
retval[i] = 0;
len = strlen(str) + 1;
if (!(copy = malloc((u_int)len)))
return((char *)0);
- bcopy(str, copy, len);
+ memcpy(copy, str, len);
return(copy);
}
return(0);
}
sin.sin_family = hp->h_addrtype;
- bcopy(hp->h_addr, (char *)&sin.sin_addr, hp->h_length);
+ memcpy((char *)&sin.sin_addr, hp->h_addr, hp->h_length);
sin.sin_port = sp->s_port;
s = socket(AF_INET, SOCK_STREAM, 0);