Skip to content

Commit

Permalink
improve error msg
Browse files Browse the repository at this point in the history
  • Loading branch information
aersam committed May 1, 2024
1 parent 573342a commit 2579d03
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/tds/codec/column_data.rs
Original file line number Diff line number Diff line change
Expand Up @@ -311,8 +311,8 @@ impl<'a> Encode<BytesMutWithTypeInfo<'a>> for ColumnData<'a> {
&mut bytes,
true,
);
if let encoding_rs::EncoderResult::Unmappable(_) = res {
return Err(crate::Error::Encoding("unrepresentable character".into()));
if let encoding_rs::EncoderResult::Unmappable(c) = res {
return Err(crate::Error::Encoding(format!("unrepresentable character:{}", c).into()));
}

if bytes.len() > vlc.len() {
Expand Down

0 comments on commit 2579d03

Please sign in to comment.