|
|
1.1 ! root 1: mmeemmccppyy() -- String Function ! 2: ! 3: #iinncclluuddee <ssttrriinngg.hh> ! 4: cchhaarr * ! 5: mmeemmccppyy(_r_e_g_i_o_n_1, _r_e_g_i_o_n_2, _n) ! 6: vvaaddddrr_tt _r_e_g_i_o_n_1; ! 7: vvaaddddrr_tt _r_e_g_i_o_n_2; ! 8: uunnssiiggnneedd iinntt _n; ! 9: ! 10: mmeemmccppyy() copies _n characters from _r_e_g_i_o_n_2 into _r_e_g_i_o_n_1. Unlike the routines ! 11: ssttrrccppyy() and ssttrrnnccppyy(), mmeemmccppyy() copies from one region to another. ! 12: Therefore, it will not halt automatically when it encounters NUL. ! 13: ! 14: mmeemmccppyy() returns _r_e_g_i_o_n_1. ! 15: ! 16: _S_e_e _A_l_s_o ! 17: ssttrrccppyy(), ssttrriinngg ffuunnccttiioonnss, ssttrriinngg.hh ! 18: ! 19: _N_o_t_e_s ! 20: If _r_e_g_i_o_n_1 and _r_e_g_i_o_n_2 overlap, the behavior of mmeemmccppyy() is undefined. ! 21: _r_e_g_i_o_n_1 should point to enough reserved memory to hold _n bytes of data; ! 22: otherwise, code or data will be overwritten.
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.