Catch SendSocket in GenerateXscript