Jump to the invalid address stated on the next line

#define LOG_ERROR(s, args...) {\
	char _error_log[128];\
	sprintf(_error_log, "[Error] at %d in %s(%s) line %d, "s, now_sec.tv_sec,__FILE__, __FUNCTION__, __LINE__, ##args);\
	logi(_error_log, "/var/log/error_fh.log");\
	printf("\033[31;48m%s\033[0m\n", _error_log);\
}

如果传给LOG_ERROR的fmt和args超过128,就会报"Jump to the invalid address stated on the next line"

改大一点儿,比如1024,这样多不了多少内存,也不那么容易遇到怪问题!

猜你喜欢

转载自blog.csdn.net/leinchu/article/details/80886629