This should check the return value (admitted, the original code should have been PyString_AS_STRING).