You're running into the dangerous mix of unsafe pointers and automatic destruction:
kornel
5
Related topics
| Topic | Replies | Views | Activity | |
|---|---|---|---|---|
|
(Why) is this safe rust?
|
11 | 2467 | July 8, 2015 | |
| You should stop telling people that safe rust is always safe | 9 | 2932 | June 6, 2016 | |
|
CString/.as_ptr() is incredibly unsafe :(
|
15 | 6194 | July 5, 2017 | |
| Dereferencing a raw pointer yields varying results | 3 | 1262 | March 8, 2016 | |
| Why should I write lifetime when using raw pointer to structure with lifetime? | 2 | 4094 | November 28, 2017 |