![]() |
| | #1 |
| Banned Join Date: Aug 2001
Posts: 532
| Linux: Sample: Client - Server (Connection Error) I was also working to create a Client Server Application. But I'm getting connection error after sometimes. (No regularity) Here is the sample code from TCP/IP V-3 by R.Stevens |
| zahid is offline | |
| | #2 |
| End Of Line Join Date: Apr 2002
Posts: 6,240
| >>But I'm getting connection error after sometimes Can you be more specific? Post your troublesome code here rather than linking to code from a book.
__________________ When all else fails, read the instructions. If you're posting code, use code tags: [code] /* insert code here */ [/code] |
| Hammer is offline | |
| | #3 |
| Banned Join Date: Aug 2001
Posts: 532
| Okay .. at least a response from one. Thank you for that. That's modified code which I'm working with. I was testing what happen when client is trying to send data and server is not running. In that situation, when I start the server, some times it works(receive data), some times not. Note: Original code does not contain #define MSG_EOF 0x100 but used. Is there any problem with that? Last edited by zahid; 09-07-2003 at 05:43 AM. |
| zahid is offline | |
| | #4 |
| End Of Line Join Date: Apr 2002
Posts: 6,240
| >>#define MSG_EOF 0x100 but used. Is there any problem with that? It depends what you're doing with it. Where are you using it in the code? Anyway, if you're putting it in the data as a trailing byte to denote EOF, it won't work as it is > 255, and therefore won't fit in one byte.
__________________ When all else fails, read the instructions. If you're posting code, use code tags: [code] /* insert code here */ [/code] |
| Hammer is offline | |
![]() |
| Thread Tools | |
| Display Modes | |
|
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Another syntax error | caldeira | C Programming | 31 | 09-05-2008 01:01 AM |
| Why wont my function exit correctly? | LightsOut06 | C Programming | 2 | 10-09-2005 09:23 PM |
| Stupid compiler errors | ChrisEacrett | C++ Programming | 9 | 11-30-2003 05:44 PM |
| Couple C questions :) | Divx | C Programming | 5 | 01-28-2003 01:10 AM |
| UNICODE and GET_STATE | Registered | C++ Programming | 1 | 07-15-2002 03:23 PM |