Function config_log

Source
pub unsafe fn config_log(callback: Option<fn(c_int, &str)>) -> Result<()>
Available on crate feature trace only.
Expand description

Set up the process-wide SQLite error logging callback.

ยงSafety

This function is marked unsafe for two reasons:

  • The function is not threadsafe. No other SQLite calls may be made while config_log is running, and multiple threads may not call config_log simultaneously.
  • The provided callback itself function has two requirements:
    • It must not invoke any SQLite calls.
    • It must be threadsafe if SQLite is used in a multithreaded way.

cf The Error And Warning Log.