backported xsp changes to stable version 1.3.3