You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If we provide a capacity too large, the program may crash.
The code to replay the crash is as below.
let capacity = 673957684733028;let _ = json::object::Object::with_capacity(capacity);
I run the code on my x86-64 machine, ubuntu18.04, and the error report is
I think it's better to restrict the capacity and return a Result instead of letting it crash alone, especially on x64 machine, where the length of usize is 64bits.
The above is found by afl.rs.
Thanks a lot.
The text was updated successfully, but these errors were encountered:
If we provide a capacity too large, the program may crash.
The code to replay the crash is as below.
I run the code on my x86-64 machine, ubuntu18.04, and the error report is
I think it's better to restrict the capacity and return a Result instead of letting it crash alone, especially on x64 machine, where the length of usize is 64bits.
The above is found by afl.rs.
Thanks a lot.
The text was updated successfully, but these errors were encountered: