Introduce is_locked

This commit is contained in:
gwenn
2018-03-31 10:22:19 +02:00
parent cccdf9735f
commit a0151f9073
3 changed files with 23 additions and 11 deletions

View File

@@ -875,7 +875,10 @@ impl InnerConnection {
&mut c_stmt,
ptr::null_mut(),
);
rc = unlock_notify::wait_for_unlock_notify(self.db, rc);
if !unlock_notify::is_locked(self.db, rc) {
break;
}
rc = unlock_notify::wait_for_unlock_notify(self.db);
if rc != ffi::SQLITE_OK {
break;
}