Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

memcpy(9) [netbsd man page]

MEMCPY(9)						   BSD Kernel Developer's Manual						 MEMCPY(9)

memcpy -- copy byte string SYNOPSIS
#include <sys/systm.h> void * memcpy(void * restrict dst, const void * restrict src, size_t len); DESCRIPTION
The memcpy() function copies len bytes from string src to string dst. The arguments must not overlap -- behavior if the arguments overlap is undefined. To copy byte strings that overlap, use memmove(9). RETURN VALUES
The memcpy() function returns the original value of dst. SEE ALSO
memmove(9) STANDARDS
The memcpy() function conforms to ISO/IEC 9899:1999 (``ISO C99''). BSD
January 2, 2012 BSD
Man Page

6 More Discussions You Might Find Interesting

1. Programming

memcpy segfaults, but not in windows

Hi Having a lil trouble with a rather simple application I'm writing. It so happens that I have to copy some data using memcpy() and so far I've been doing just fine compiling it with VC.Net and running it on Windows XP. Now I'm trying to port the thing to Solaris (which shouldn't really be too... (3 Replies)
Discussion started by: khoma
3 Replies

2. Programming

Problem with memcpy

Hi , I am having records in a file like 00412772784705041008FRUITFUL STRWBRRY 00412772784703041008FRUITFUL STRWBERE 00000570632801448078 X i have declared a structure like typedef struct { char Uname; char Pname; ... (4 Replies)
Discussion started by: arunkumar_mca
4 Replies

3. Programming

Segmentation Fault by memcpy

Hello everybody, I'm coding a test program for ARP protocol, and i don't know why i'm getting a SIGSEGV, i traced it with gdb and it says it's due to the memcpy function from /lib/ Program received signal SIGSEGV, Segmentation fault. 0xb7e9e327 in memcpy () from /lib/ This... (5 Replies)
Discussion started by: Zykl0n-B
5 Replies

4. Programming

memcpy error

I am getting segmentation fault in memcpy.I have given sufficient memory but i dont know why it is occurring char *finalptr = ( char *)malloc(1048576* sizeof(char)); finaloffset=0;have=685516; memcpy(&(finalptr)+finaloffset,out,have); finaloffset=685516;have=359910;... (23 Replies)
Discussion started by: rajsekhar28
23 Replies

5. Programming

Signal SEGV (no mapping at the fault address) in _memcpy at 0xff0b07c0

Hi, I am unable to copy the cursor value into character variable which is defined in nested structure by pointer. typedef struct aaa { unsigned char device_type; unsigned char encrypt; unsigned short rec_len; } ABC; typedef ABC *Pabc; typedef struct def { ABC... (9 Replies)
Discussion started by: gthangav
9 Replies

6. Shell Programming and Scripting

Undefined reference to memcpy@GLIBC_2.14

Dear All, I am trying to compile OpenFOAM-1.7.x in RHEL. I could not able to compile some of the applications because of libc version issues. It is saying undefined reference to memcpy@GLIBC_2.14 Can anybody look into it? Thanks & Regards, linuxUser_ (3 Replies)
Discussion started by: linuxUser_
3 Replies