Fixes for the SWIG wrapper.