Implement SysAllocStringLen and use instead of SysAllocString. Closes #29

This fixes issue #29.