Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

memcpy in string.h

Name: Anonymous 2013-05-25 16:01

$ man memcpy
MEMCPY(3)                          Linux Programmer's Manual                         MEMCPY(3)



NAME
       memcpy - copy memory area

SYNOPSIS
       #include <string.h>


Why the fuck is memcpy in string.h? It is not exclusively for dealing with strings, shouldn't it be with malloc, exit & co. in stdlib.h?

I'm aware that this is because of the ISO specification, and that it is probably like this for historical reasons, but what are those historical reasons?

Name: Anonymous 2013-05-26 14:57

http://www.scs.stanford.edu/histar/src/pkg/uclibc/include/memory.h

#ifndef    _MEMORY_H
#define    _MEMORY_H    1

#include <features.h>


#ifndef    _STRING_H
# include <string.h>
#endif    /* string.h  */


#endif    /* memory.h  */


How the mighty have fallen.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List