fixed missing check for disallow_nul (closes #1)