Fixed segment fault bug when use logging API at i386 platform

This bug cause by qb_vsprintf_serialize function. It parse "%llx" format
as _long_ other than _long long_.

At x86_64 platform, both sizeof(long) and sizeof(long long) is 8, this
issue would not be triggered, so we could only catch it at i386.

Signed-off-by: Yunkai Zhang <qiushu.zyk@taobao.com>
Signed-off-by: Angus Salkeld <asalkeld@redhat.com>
This commit is contained in:
Yunkai Zhang 2011-10-13 17:59:55 +08:00 committed by Angus Salkeld
parent dc3a061e98
commit 8a673559e7

View File

@ -314,6 +314,7 @@ reprocess:
if (*format == 'l') {
type_long = 0;
type_longlong = 1;
format++;
}
goto reprocess;
case 'd': /* int argument */