contain-rs / linked-hash-map

A HashMap wrapper that holds key-value pairs in insertion order
https://contain-rs.github.io/linked-hash-map/linked_hash_map/
Apache License 2.0
169 stars 60 forks source link

Fix UB caused by uninitialized reference #106

Closed Kogia-sima closed 3 years ago

Kogia-sima commented 3 years ago

This PR fix UB caused by the reference to uninitialized key and value in drop_empty_node function. This change also keep MSRV unchanged because linked-hash-map crate already use std::alloc::alloc in ensure_guard_node method.

fix #104