bcopy(3)

๐Ÿ’– bcopy(3) โ€” byte copy ๐Ÿ’–

okay bestie, listen up, we're doing a bcopy(3) deep dive and it's a whole vibe. this is the byte-copying girlie from the good old days. she's an icon, she's a legend, and she is also, unfortunately, deprecated. but we still stan a historical queen.


๐Ÿ“š LIBRARY

Standard C library (libc, -lc). yes bestie, she lives in libc itself, she's not some third-party npm situation.


โœจ SYNOPSIS

#include <strings.h>

[[deprecated]] void bcopy(size_t n;
                          const void src[n], void dest[n], size_t n);

notice the [[deprecated]] right there in the signature?? that's not me being dramatic, that's literally in the header. the compiler is judging you and honestly she has a point. ๐Ÿซถ


๐ŸŒธ DESCRIPTION

the way that bcopy() just copies n bytes from src to dest. that's it. that's the whole job. simple, efficient, no notes.

and the tea?? the result is correct even when both areas overlap. slay. she eats that. overlap? never heard of her, doesn't matter, still correct. โœจ


๐Ÿ’€ RETURN VALUE

None. she gives you nothing back. no return value, no vibe check, no little status code, nothing. void energy fr fr. you get the copy and that's your whole entire prize.


๐ŸŽ€ ATTRIBUTES

for an explanation of the terms used in this section, see attributes(7).

  • Interface: bcopy()
  • Attribute: Thread safety
  • Value: MT-Safe ๐Ÿ‘‘

so she's MT-Safe, which means multithreading besties can share her without anything getting weird. iconic behaviour only.


๐Ÿ“œ STANDARDS

None. she's not in any standard. she's just out here, existing, ungoverned, a free spirit. ๐Ÿฆ‹


๐Ÿ•ฐ๏ธ HISTORY

  • 4.3BSD. that's where she comes from. vintage. retro. historical artifact energy.
  • Marked as LEGACY in POSIX.1-2001: use memcpy(3) or memmove(3) in new programs.
  • > โš ๏ธ CAREFUL BESTIE: note that the first two arguments are interchanged for memcpy(3) and memmove(3). like, she put src first and then dest, and they flipped it. so if you're porting code and you just swap the name and keep the args, you will copy in the wrong direction and it will be a bad time. do NOT do that. ๐Ÿ’€
  • POSIX.1-2008 removes the specification of bcopy() entirely. she's not just legacy, she's gone from the spec. gone-gone. ๐Ÿ˜ญ

๐Ÿ‘€ SEE ALSO


and that's the whole page, bestie. this one comes to you from Linux man-pages 6.20, dated 2026-08-10, in the bcopy(3) section of the Library Functions Manual. go use memmove(3) instead, mwah ๐Ÿ’…โœจ

๐Ÿ“ฆ where this page comes from
  • arch rolling: man-pages 6.20-1 ยท BSD-2-Clause AND BSD-3-Clause AND BSD-4.3TAHOE AND BSD-4-Clause-UC AND GPL-1.0-or-later AND GPL-2.0-only AND GPL-2.0-or-later AND GPL-3.0-or-later AND LGPL-3.0-linking-exception AND LGPL-3.0-or-later AND LicenseRef-Public-Domain AND LicenseRef-UltraPermissive AND Linux-man-pages-1-para AND Linux-man-pages-copyleft AND Linux-man-pages-copyleft-2-para AND Linux-man-pages-copyleft-var AND MIT AND Spencer-94
  • nixpkgs unstable: man-pages 6.20
  • ๐Ÿ“œ the page's license: Linux-man-pages-copyleft
  • ๐Ÿ’– girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms