Android WiFi file transfer - code study