+ Reply to Thread
Results 1 to 2 of 2

Thread: Implement memcpy

  1. #1
    Surfer is offline Senior Member
    Join Date
    Mar 2010
    Posts
    321

    Implement memcpy

    Implement memcpy

  2. #2
    game.iiith Guest
    Code:
    void memcpy(void *src, void *dest, int size) {
            int i=0;
            while ( i < size ) {
                    *((char *)dest + i) = *((char *)src + i);
                    i++;
            }
    }
    Notice that memcpy does not take care of overlaps. In case of overlaps use memmove.

    Avi
    Avi Dullu&#039;s Code Arena

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Implement and test memcpy function
    By TopGun in forum Microsoft
    Replies: 0
    Last Post: 2nd June 2008, 15:24

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts