mirror of
https://github.com/chatmail/core.git
synced 2026-05-19 23:06:32 +03:00
be tolerant when reading unexpected NULL from the database and treat this as an empty string, compatible to core-c
This commit is contained in:
@@ -478,8 +478,7 @@ pub fn dc_msg_load_from_db<'a>(context: &'a Context, id: u32) -> Result<Message<
|
|||||||
text = String::from_utf8_lossy(buf).into_owned();
|
text = String::from_utf8_lossy(buf).into_owned();
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
warn!(context, 0, "dc_msg_load_from_db: could not get text column for id {}", id);
|
text = "".to_string();
|
||||||
text = "[ Could not read from db ]".to_string();
|
|
||||||
}
|
}
|
||||||
msg.text = Some(text);
|
msg.text = Some(text);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user