By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
439,986 Members | 1,583 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 439,986 IT Pros & Developers. It's quick & easy.

Creating and sending a packet via a socket

P: 9
I have created a Packet as a structure. i am not able to send the packet through the send() because what i have understood it sends only strings. Is there any way to send the packet as a structure itself??
Basically i want to know how to send a packet via socket connection?
Mar 30 '08 #1
Share this Question
Share on Google+
1 Reply


P: 75
I have created a Packet as a structure. i am not able to send the packet through the send() because what i have understood it sends only strings. Is there any way to send the packet as a structure itself??
Basically i want to know how to send a packet via socket connection?
hmmh, try using pickle module , google for it ;)

pickle the data, which converts it to string and then send it. and the receiver can unpickle it then from the string... I don't have tried pickle but I think that it might work like that
Mar 31 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.