PiegOS/kernel/Helpers/memory.cpp
2015-07-21 14:23:57 +04:00

23 lines
289 B
C++

#include "./memory.hpp"
#include "./types.hpp"
int memcpy(u32 source, u32 dest, u32 size){
u32 *sourceTmp=(u32 *)source;
u32 *destTmp=(u32 *)dest;
u32 progress=0;
while(progress != size){
*destTmp=*sourceTmp;
sourceTmp++;
destTmp++;
progress++;
}
return progress;
}