mirror of
https://github.com/pgvector/pgvector.git
synced 2026-07-22 20:15:46 +08:00
Compare commits
2 Commits
0e557b1d18
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a6420355c5 | ||
|
|
73356ecfa7 |
@@ -1233,7 +1233,7 @@ Note: Replace `18` with your Postgres server version
|
|||||||
Install the FreeBSD package with:
|
Install the FreeBSD package with:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
pkg install postgresql17-pgvector
|
pkg install postgresql18-pgvector
|
||||||
```
|
```
|
||||||
|
|
||||||
or the port with:
|
or the port with:
|
||||||
|
|||||||
@@ -25,8 +25,8 @@ VectorArrayInit(int maxlen, int dimensions, Size itemsize)
|
|||||||
{
|
{
|
||||||
VectorArray res;
|
VectorArray res;
|
||||||
|
|
||||||
if (maxlen < 1 || dimensions < 1)
|
if (maxlen < 1 || dimensions < 1 || itemsize == 0)
|
||||||
elog(ERROR, "safety check failed");
|
elog(ERROR, "cannot create vector array");
|
||||||
|
|
||||||
/* Ensure items are aligned to prevent UB */
|
/* Ensure items are aligned to prevent UB */
|
||||||
itemsize = MAXALIGN(itemsize);
|
itemsize = MAXALIGN(itemsize);
|
||||||
|
|||||||
Reference in New Issue
Block a user