Issue #4830 fix
auto merge of #4861 : sethpink/rust/incoming, r=catamorphism

Fix for issue #4830.