Wener Notes

C Cookbook

约 1 分钟阅读
标签:实践手册
bannedaltreason
ctime_r, asctime_rstrftime,strbuf_addftimereentrant, but no check the buffer is long enough
gmtime,localtime,ctime,asctimereturn pointers to shared storage, not thread-safe
sprintf,vsprintfstrbuf,xstrfmt,xsnprintfbuffer overflow
strcpy,strcat,strbuf,xstrfmt,xsnprintf越界
strncpystrlcpy,strbuf,xstrfmt,xsnprintfNUL terminator
strncatquadratic behavior

定义宏移除方法

c
#define	assert(x) (void)0

关联信息

反向链接、本文链接的其他页面和外部资料。

References

GitHub2 条
最近更新commit 6b3009dEdit

On this page