Avoid accessing array outside array bounds
Avoid accessing array outside array bounds

The @outarr array may at this point be empty and using subscript -1
to reach the last element will thus throw an uninitialized error.
Test for array contents before accessing any elements to avoid the
error and to exit early since the block by definition isn't of
interest. Observed in the wild for the bfv_partition test suite.

xuegang/gpdb,xinzweb/gpdb,kaknikhil/gpdb,rvs/gpdb,rvs/gpdb,Chibin/gpdb,kaknikhil/gpdb,ashwinstar/gpdb,Quikling/gpdb,lintzc/gpdb,cjcjameson/gpdb,janebeckman/gpdb,greenplum-db/gpdb,edespino/gpdb,yuanzhao/gpdb,chrishajas/gpdb,cjcjameson/gpdb,ashwinstar/gpdb,yuanzhao/gpdb,rvs/gpdb,Chibin/gpdb,Quikling/gpdb,edespino/gpdb,xinzweb/gpdb,jmcatamney/gpdb,Chibin/gpdb,0x0FFF/gpdb,yuanzhao/gpdb,greenplum-db/gpdb,janebeckman/gpdb,kaknikhil/gpdb,greenplum-db/gpdb,edespino/gpdb,royc1/gpdb,lisakowen/gpdb,chrishajas/gpdb,yuanzhao/gpdb,Quikling/gpdb,janebeckman/gpdb,xuegang/gpdb,Chibin/gpdb,adam8157/gpdb,Quikling/gpdb,chrishajas/gpdb,50wu/gpdb,kaknikhil/gpdb,50wu/gpdb,CraigHarris/gpdb,adam8157/gpdb,Chibin/gpdb,kaknikhil/gpdb,rvs/gpdb,janebeckman/gpdb,ashwinstar/gpdb,rvs/gpdb,royc1/gpdb,ashwinstar/gpdb,50wu/gpdb,lintzc/gpdb,janebeckman/gpdb,janebeckman/gpdb,adam8157/gpdb,rvs/gpdb,0x0FFF/gpdb,chrishajas/gpdb,greenplum-db/gpdb,jmcatamney/gpdb,0x0FFF/gpdb,rvs/gpdb,50wu/gpdb,adam8157/gpdb,xuegang/gpdb,Chibin/gpdb,rvs/gpdb,cjcjameson/gpdb,yuanzhao/gpdb,lisakowen/gpdb,ashwinstar/gpdb,cjcjameson/gpdb,chrishajas/gpdb,xinzweb/gpdb,Chibin/gpdb,yuanzhao/gpdb,lisakowen/gpdb,janebeckman/gpdb,rvs/gpdb,0x0FFF/gpdb,royc1/gpdb,royc1/gpdb,xuegang/gpdb,cjcjameson/gpdb,royc1/gpdb,Chibin/gpdb,Quikling/gpdb,edespino/gpdb,adam8157/gpdb,Quikling/gpdb,yuanzhao/gpdb,Chibin/gpdb,jmcatamney/gpdb,lintzc/gpdb,xinzweb/gpdb,Chibin/gpdb,xinzweb/gpdb,Quikling/gpdb,chrishajas/gpdb,xuegang/gpdb,royc1/gpdb,ashwinstar/gpdb,CraigHarris/gpdb,xinzweb/gpdb,Quikling/gpdb,lintzc/gpdb,CraigHarris/gpdb,CraigHarris/gpdb,lintzc/gpdb,0x0FFF/gpdb,adam8157/gpdb,greenplum-db/gpdb,jmcatamney/gpdb,adam8157/gpdb,royc1/gpdb,royc1/gpdb,0x0FFF/gpdb,edespino/gpdb,jmcatamney/gpdb,janebeckman/gpdb,xuegang/gpdb,ashwinstar/gpdb,Quikling/gpdb,jmcatamney/gpdb,cjcjameson/gpdb,lisakowen/gpdb,yuanzhao/gpdb,CraigHarris/gpdb,CraigHarris/gpdb,xuegang/gpdb,jmcatamney/gpdb,xinzweb/gpdb,CraigHarris/gpdb,edespino/gpdb,cjcjameson/gpdb,kaknikhil/gpdb,xinzweb/gpdb,kaknikhil/gpdb,rvs/gpdb,xuegang/gpdb,50wu/gpdb,lintzc/gpdb,lintzc/gpdb,adam8157/gpdb,greenplum-db/gpdb,yuanzhao/gpdb,kaknikhil/gpdb,lintzc/gpdb,lisakowen/gpdb,lisakowen/gpdb,jmcatamney/gpdb,edespino/gpdb,janebeckman/gpdb,chrishajas/gpdb,kaknikhil/gpdb,janebeckman/gpdb,greenplum-db/gpdb,edespino/gpdb,ashwinstar/gpdb,xuegang/gpdb,0x0FFF/gpdb,kaknikhil/gpdb,50wu/gpdb,50wu/gpdb,Quikling/gpdb,yuanzhao/gpdb,0x0FFF/gpdb,greenplum-db/gpdb,edespino/gpdb,cjcjameson/gpdb,CraigHarris/gpdb,lisakowen/gpdb,50wu/gpdb,lintzc/gpdb,lisakowen/gpdb,cjcjameson/gpdb,cjcjameson/gpdb,edespino/gpdb,chrishajas/gpdb,CraigHarris/gpdb