Search:
Type: Posts; User: zio_mangrovia
Search:
Search took 0.04 seconds.
-
November 12th, 2023, 05:53 AM
In std C89 can you suggest me where to sei KeepAlive ?
In what primitive? Socket ? send ? recv ? And about timing value ?
-
November 12th, 2023, 05:50 AM
I'm referencing to this one sockaddr_in
Why it has been implemented a structure to contain af_family, port and ip address ?
-
November 11th, 2023, 10:23 AM
Ok thank you.
I thought this behaviour of KeepAlive could to be useful only to prevent some application states before send/recv was used. what do you think ?
-
November 10th, 2023, 07:27 AM
What is reason to put data (ip, port) into structure of sockaddr to use connect primitive or bind ?
It could to be easier to pass as single parameters (ip or ports) instead to pass the structure ?...
-
November 10th, 2023, 07:24 AM
I'm writing network app client/server with tcp persistent connection. If network went down, both client and server socket are kept opened, they are not closed automatically. So how can I prevent this...
-
November 8th, 2023, 09:12 AM
If I want to write code for C89 It's necessary to use fflush(stdout) during message print to output ?
E.g. with printf("message") .
-
September 23rd, 2023, 03:34 AM
Lets' suppose to convert int type from host byte order to network byte order to send data to another host and I want to use htonl function.
Host byte order depends on computer architecture...
-
July 29th, 2023, 01:31 PM
On the same machine I created client and server application where client always starts communication and open socket to server on port 2001.
Netstat shows:
1) tcp 0 0 0.0.0.0:2001 ...
-
July 24th, 2023, 11:58 AM
In code when you use exit() instruction to close process, It's good practise close sockets or files and deallocate data structure before invoke exit(). I thought when process is auto-destroyed this...
-
July 17th, 2023, 09:05 AM
I noted select return 1 when remote process is receiving ctrl-c while I thought it received -1 value.
I create server process where stdin and communication sockets are inserted into fd_set to...
-
July 16th, 2023, 02:31 AM
In network where process C is client and another one S is server,
C is waiting network message or user input by select function, idem S.
If I kill process A, RECV of server S receives -1 value...
-
July 15th, 2023, 04:54 AM
It's very interesting what you are saying: for some reason, it calls send() several times
so It's possible for few byte for some reason bytes can to be sent/recevived in multiple call so It's...
-
July 15th, 2023, 02:06 AM
But this behaviour depends of how application Is made, according to your example programmer decides how to send data:
programmer can decide to send "AB"or "ABC" on 1st SEND , so RECV will ...
-
July 15th, 2023, 01:48 AM
if you run man recv in return value section says:
On success, a file descriptor for the new socket is returned. On error, -1 is returned, and errno is set to indicate the error
-
July 15th, 2023, 01:45 AM
My environment is Ubuntu OS and compiler is gcc
-
July 15th, 2023, 01:33 AM
Let's suppose programmer doesn't know buffer size and It's need to send 8192 Bytes, how programmer should have to set cycle to send data by TCP socket ? I think by multiple blocks of data sending......
-
July 14th, 2023, 08:24 AM
TCP
How you suggested, It likes there is limit to send bytes in a single task ? What is maximum size of buffer to receive / send data at one time ?
-
July 13th, 2023, 10:18 AM
I'd like to know if return code test of recv function in my C application, according to std c89, is right.
While (1) {
...
ret = recv(socket, buffer, lun, 0);
if ( ret == -1 ||...
-
If I had these 2 module :
utility.c + utility.h (linked list functions)
server.c + server.h
every .header file contains declaration of functions plus data structure because I want to isolate...
-
June 30th, 2023, 11:09 AM
thanks to all.
I need to understand and your confirm helped me.
-
June 27th, 2023, 12:33 PM
I thank you very much for your code but my target is understand C code which I indicated, even if this doesn't work.
Please help to understand the following lines and afterwards I'll be able to...
-
June 26th, 2023, 03:16 PM
I know infact I copied string into another one as job string. Same thing for every line (which is tokenized) is copied to another one for extracting words.
-
June 26th, 2023, 03:11 PM
It's true only if you use 2nd strtok with NULL as 1st parameter that is strtok(NULL,delimiter); I know strtok has no state.
In my case strtok is run as It was always the first time with...
-
June 25th, 2023, 03:58 PM
I read several documents about strtok according to C89/90, that is my target.
I want to use only strtok and I need to divide string into lines by '#' delimiter and line into words by ';' delimiter....
-
June 23rd, 2023, 10:28 AM
I have 4 module.c (a,b,c,d,) and 2 ( a, b) of them share a data structure so I think to declare the data structure into a header file which will be referenced both into a and into b module.
It's...
|
Click Here to Expand Forum to Full Width
|