Fix DB access cleaning

This commit is contained in:
Johan Pascal 2019-06-27 15:49:57 +07:00
parent c13228870d
commit daa5e601ea

View file

@ -36,7 +36,9 @@ function linphonedb_fetch($result) {
}
function linphonedb_clean($result) {
mysqli_free_result($result);
if (!is_bool($result)) { // some query may return a boolean, in that case we must not call free
mysqli_free_result($result);
}
}
function linphonedb_close($conn) {