gecko/xpcom/tests/static-checker/StackCondBad.cpp

13 lines
135 B
C++

#include "nscore.h"
struct NS_STACK_CLASS A
{
};
A* tfunc(int len)
{
A arr[5];
A* a = len <= 5 ? arr : new A[len];
return a;
}