In reply to Pavel:
This is because your master implementation in send_data() is incorrect. You need to fix it.