[Skiboot] [PATCH] core: Fix backtrace for gcc 6
Vasant Hegde
hegdevasant at linux.vnet.ibm.com
Tue Mar 1 14:49:49 AEDT 2016
On 03/01/2016 08:51 AM, Joel Stanley wrote:
> On Mon, Feb 29, 2016 at 3:56 PM, Vasant Hegde
> <hegdevasant at linux.vnet.ibm.com> wrote:
>>> - unsigned long *fp = __builtin_frame_address(1);
>>> + unsigned long *fp = __builtin_frame_address(0);
>>>
>>> *count = 0;
>>> while(room) {
>>> + fp = (unsigned long *)fp[0];
>>
>>
>> What if fp is NULL?
>
> We dereference a null pointer.
>
> Will we ever find ourselves in the situation where there is no frame pointer?
Never. But I doubt code analysis tools understand that and we may start
getting warnings ;-)
-Vasant
More information about the Skiboot
mailing list