Click here to Skip to main content
15,913,709 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: CWnd question Pin
PJ Arends29-Jul-04 7:16
professionalPJ Arends29-Jul-04 7:16 
GeneralSpecific POST/GET request header Pin
Member 78763029-Jul-04 6:04
Member 78763029-Jul-04 6:04 
GeneralRe: Specific POST/GET request header Pin
Ravi Bhavnani29-Jul-04 6:24
professionalRavi Bhavnani29-Jul-04 6:24 
GeneralRe: Specific POST/GET request header Pin
Jeff Bogan29-Jul-04 6:25
Jeff Bogan29-Jul-04 6:25 
GeneralOwn ProgressBar Pin
act_x29-Jul-04 4:45
act_x29-Jul-04 4:45 
GeneralRe: Own ProgressBar Pin
Jaime Stuardo29-Jul-04 7:43
Jaime Stuardo29-Jul-04 7:43 
QuestionHow do I insert an audio stream to video file? Pin
javih51129-Jul-04 3:49
javih51129-Jul-04 3:49 
Generalsend() and recv() sockets Pin
ns29-Jul-04 3:31
ns29-Jul-04 3:31 
I have to use these plain sockets, not MFC. If I do one send() from one app, the other can get it with recv. This works. What I really need to do is write a number of separate chunks to a socket, then have the other one read it at its leisure. I tried write() but that doesnt work....it doesnt like the socket handle I get from socket(). So I tried two sends in one and two recvs in the other thinking that my multiple sends will get queued up and the other can recv the info at its leisure in measured doses

eg.

1. send the header

2. send the image

--------------------
1 recv the header

2. recv the image

If I have two sends and only 1 recv I can get the two things sent in the buffer that recv() has.

However i really need to recv() stuff into separate buffers. I thought read and write would work, but it doesnt.

How do I do this, so that I can recv stuff sent in two sends into two recv() buffers? Do I have to do an communication between processes? Like send 1 thing, wait and get a confirm from the other app on receipt, then send my second chunk which the other app will now be waiting for?


send() 1st chunk

recv() -- other app got it, so send again

send() 2nd chunk


while on the other end I have:

recv() 1st chunk

send() -- to tell its okay to send second chunk

recv() second chunk.....

I was hoping I could just read my two chunks and just send() them one after another....

Thanks,
sb
GeneralRe: send() and recv() sockets Pin
Peter Weyzen29-Jul-04 10:49
Peter Weyzen29-Jul-04 10:49 
GeneralIrDA traffic statistics Pin
dima_matrix29-Jul-04 3:22
dima_matrix29-Jul-04 3:22 
Generalprogram like the norton ghost Pin
X204029-Jul-04 2:59
X204029-Jul-04 2:59 
Generalexample code of using IPicture to save bitmap image as gif, jpg ... Pin
includeh1029-Jul-04 2:30
includeh1029-Jul-04 2:30 
Questionwher is search engine to find a poster? Pin
includeh1029-Jul-04 2:24
includeh1029-Jul-04 2:24 
AnswerRe: wher is search engine to find a poster? Pin
David Crow29-Jul-04 3:11
David Crow29-Jul-04 3:11 
AnswerRe: wher is search engine to find a poster? Pin
Michael P Butler29-Jul-04 3:32
Michael P Butler29-Jul-04 3:32 
GeneralRe: wher is search engine to find a poster? Pin
includeh1029-Jul-04 5:40
includeh1029-Jul-04 5:40 
GeneralRe: wher is search engine to find a poster? Pin
Michael P Butler29-Jul-04 5:44
Michael P Butler29-Jul-04 5:44 
GeneralRe: wher is search engine to find a poster? Pin
includeh1029-Jul-04 6:03
includeh1029-Jul-04 6:03 
GeneralMultiple project solution Pin
HohohoMyHo29-Jul-04 1:31
HohohoMyHo29-Jul-04 1:31 
GeneralRe: Multiple project solution Pin
SOCM_FP_CPP29-Jul-04 2:29
SOCM_FP_CPP29-Jul-04 2:29 
GeneralRe: Multiple project solution Pin
HohohoMyHo29-Jul-04 2:43
HohohoMyHo29-Jul-04 2:43 
GeneralRe: Multiple project solution Pin
HohohoMyHo29-Jul-04 4:03
HohohoMyHo29-Jul-04 4:03 
GeneralRe: Multiple project solution Pin
Antti Keskinen29-Jul-04 8:57
Antti Keskinen29-Jul-04 8:57 
GeneralRe: Multiple project solution Pin
HohohoMyHo30-Jul-04 12:07
HohohoMyHo30-Jul-04 12:07 
GeneralPort Mapper Pin
abdul moeed29-Jul-04 0:56
abdul moeed29-Jul-04 0:56 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.