View Single Post
  #4   (View Single Post)  
Old 21st August 2011
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Helpful companion
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223

To be more specific, the warning is emitted by the GNU linker, it is used by OpenBSD to warn when deprecated or unsafe functions/symbols are referenced by programs.

The follow section of code from the C library.. lib/libc/string/strcpy.c.
#if defined(APIWARN)
    "warning: strcpy() is almost always misused, please use strlcpy()");
Expands to this, give or take a few quotes:
#if defined(APIWARN)
__asm__(".section .gnu.warning." __STRING(strcpy) " ; .ascii \"" warning: strcpy() is almost always misused, please use strlcpy() "\" ; .text");
Tell the owner the problem is unavoidable and is not harmful, the only possible way disable these warnings is to modify the C library. Don't do that.
Reply With Quote