1.Dd January 24, 2024 2.Dt SQLITE_DESERIALIZE_FREEONCLOSE 3 3.Os 4.Sh NAME 5.Nm SQLITE_DESERIALIZE_FREEONCLOSE , 6.Nm SQLITE_DESERIALIZE_RESIZEABLE , 7.Nm SQLITE_DESERIALIZE_READONLY 8.Nd flags for sqlite3_deserialize() 9.Sh SYNOPSIS 10.In sqlite3.h 11.Fd #define SQLITE_DESERIALIZE_FREEONCLOSE 12.Fd #define SQLITE_DESERIALIZE_RESIZEABLE 13.Fd #define SQLITE_DESERIALIZE_READONLY 14.Sh DESCRIPTION 15The following are allowed values for 6th argument (the F argument) 16to the sqlite3_deserialize(D,S,P,N,M,F) 17interface. 18.Pp 19The SQLITE_DESERIALIZE_FREEONCLOSE means that the database serialization 20in the P argument is held in memory obtained from 21.Fn sqlite3_malloc64 22and that SQLite should take ownership of this memory and automatically 23free it when it has finished using it. 24Without this flag, the caller is responsible for freeing any dynamically 25allocated memory. 26.Pp 27The SQLITE_DESERIALIZE_RESIZEABLE flag means that SQLite is allowed 28to grow the size of the database using calls to 29.Fn sqlite3_realloc64 . 30This flag should only be used if SQLITE_DESERIALIZE_FREEONCLOSE is 31also used. 32Without this flag, the deserialized database cannot increase in size 33beyond the number of bytes specified by the M parameter. 34.Pp 35The SQLITE_DESERIALIZE_READONLY flag means that the deserialized database 36should be treated as read-only. 37.Sh IMPLEMENTATION NOTES 38These declarations were extracted from the 39interface documentation at line 10754. 40.Bd -literal 41#define SQLITE_DESERIALIZE_FREEONCLOSE 1 /* Call sqlite3_free() on close */ 42#define SQLITE_DESERIALIZE_RESIZEABLE 2 /* Resize using sqlite3_realloc64() */ 43#define SQLITE_DESERIALIZE_READONLY 4 /* Database is read-only */ 44.Ed 45.Sh SEE ALSO 46.Xr sqlite3_malloc 3 47