We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1fff644 commit cd358b8Copy full SHA for cd358b8
src/de/mod.rs
@@ -159,7 +159,9 @@ fn read_f128<R: Read + ?Sized>(reader: &mut R) -> Result<Decimal128> {
159
#[cfg(feature = "decimal128")]
160
#[inline]
161
fn read_f128<R: Read + ?Sized>(reader: &mut R) -> Result<Decimal128> {
162
- let mut local_buf = [0u8; 16];
+ use std::mem;
163
+
164
+ let mut local_buf: [u8; 16] = unsafe { mem::MaybeUninit::uninit().assume_init() };
165
reader.read_exact(&mut local_buf)?;
166
let val = unsafe { Decimal128::from_raw_bytes_le(local_buf) };
167
Ok(val)
0 commit comments