fixing packet structure for file transfer