pgsql: In array_position()/array_positions(), beware of empty input arr

2023-05-04 Thread Tom Lane
In array_position()/array_positions(), beware of empty input array. These functions incautiously fetched the array's first lower bound even when the array is zero-dimensional, thus fetching the word after the allocated array space. While almost always harmless, with very bad luck this could resul

pgsql: In array_position()/array_positions(), beware of empty input arr

2023-05-04 Thread Tom Lane
In array_position()/array_positions(), beware of empty input array. These functions incautiously fetched the array's first lower bound even when the array is zero-dimensional, thus fetching the word after the allocated array space. While almost always harmless, with very bad luck this could resul

pgsql: In array_position()/array_positions(), beware of empty input arr

2023-05-04 Thread Tom Lane
In array_position()/array_positions(), beware of empty input array. These functions incautiously fetched the array's first lower bound even when the array is zero-dimensional, thus fetching the word after the allocated array space. While almost always harmless, with very bad luck this could resul

pgsql: In array_position()/array_positions(), beware of empty input arr

2023-05-04 Thread Tom Lane
In array_position()/array_positions(), beware of empty input array. These functions incautiously fetched the array's first lower bound even when the array is zero-dimensional, thus fetching the word after the allocated array space. While almost always harmless, with very bad luck this could resul

pgsql: In array_position()/array_positions(), beware of empty input arr

2023-05-04 Thread Tom Lane
In array_position()/array_positions(), beware of empty input array. These functions incautiously fetched the array's first lower bound even when the array is zero-dimensional, thus fetching the word after the allocated array space. While almost always harmless, with very bad luck this could resul

pgsql: In array_position()/array_positions(), beware of empty input arr

2023-05-04 Thread Tom Lane
In array_position()/array_positions(), beware of empty input array. These functions incautiously fetched the array's first lower bound even when the array is zero-dimensional, thus fetching the word after the allocated array space. While almost always harmless, with very bad luck this could resul