| 1 : | anton | 1.1 | char *memmove(char *dest, const char *src, long n) |
| 2 : | { | ||
| 3 : | int i; | ||
| 4 : | |||
| 5 : | if (dest<src) | ||
| 6 : | for (i=0; i<n; i++) | ||
| 7 : | dest[i]=src[i]; | ||
| 8 : | else | ||
| 9 : | for(i=n-1; i>=0; i--) | ||
| 10 : | dest[i]=src[i]; | ||
| 11 : | return dest; | ||
| 12 : | } |
|
CVS Admin Powered by ViewCVS 1.0-dev |
ViewCVS and CVS Help |