xref: /netbsd-src/external/public-domain/sqlite/man/sqlite3_blob_close.3 (revision 51db93b1e55befe059298d8824a0c056de72eba2)
1.Dd December 19, 2018
2.Dt SQLITE3_BLOB_CLOSE 3
3.Os
4.Sh NAME
5.Nm sqlite3_blob_close
6.Nd Close A BLOB Handle
7.Sh SYNOPSIS
8.Ft int
9.Fo sqlite3_blob_close
10.Fa "sqlite3_blob *"
11.Fc
12.Sh DESCRIPTION
13This function closes an open BLOB handle.
14The BLOB handle is closed unconditionally.
15Even if this routine returns an error code, the handle is still closed.
16.Pp
17If the blob handle being closed was opened for read-write access, and
18if the database is in auto-commit mode and there are no other open
19read-write blob handles or active write statements, the current transaction
20is committed.
21If an error occurs while committing the transaction, an error code
22is returned and the transaction rolled back.
23.Pp
24Calling this function with an argument that is not a NULL pointer or
25an open blob handle results in undefined behaviour.
26Calling this routine with a null pointer (such as would be returned
27by a failed call to sqlite3_blob_open()) is a harmless
28no-op.
29Otherwise, if this function is passed a valid open blob handle, the
30values returned by the sqlite3_errcode() and sqlite3_errmsg() functions
31are set before returning.
32.Sh SEE ALSO
33.Xr sqlite3_blob 3 ,
34.Xr sqlite3_blob_open 3
35