Sponsored Content
Top Forums Programming Looping problems socket programming in C Post 302545257 by neutronscott on Sunday 7th of August 2011 09:22:23 PM
Old 08-07-2011
The server reads once and exits... So the client can't loop if the server doesn't...
 

10 More Discussions You Might Find Interesting

1. Programming

Socket programming

Suppose i am writing a C program which is going to use Socket calls. I want to use a Unix port for my Socket. How can i determine a port which is not already in use? (1 Reply)
Discussion started by: Nadeem Mistry
1 Replies

2. Programming

Socket Programming socket

Hello, I actually try to make client-server program. I'm using SCO OpenServer Release 5.0.0 and when I try to compile my code (by TELNET) I've got this error : I'm just using this simple code : and I get the same error if I use : If someone can help me, Thanks (2 Replies)
Discussion started by: soshell
2 Replies

3. Programming

Socket Programming

Hi , I'm facing the following problem in socket programming. My structure is struct { int i; char *str; }samp; I'm creating the pointer to this structure and assigning the value to the structure members and send via the socket to the another process. The receiver process when... (7 Replies)
Discussion started by: arunviswanath
7 Replies

4. Programming

Socket programming

Hello!:) I'm trying to do some socket programming based on the following situation: I have a directory service named Casino that will hold all the information regarding the gamers that will try to connect to it in order to play a game(for example (Blackjack).Once they make the login they are... (4 Replies)
Discussion started by: maracumbigo
4 Replies

5. IP Networking

socket programming

Hello Everyone Iam working on tcp/ip programming.with some time interval server has to send data.client has to close the connection and to open the connection between the time interval.this is the scenario when iam closing the connection in client side the connection terminates.how to... (1 Reply)
Discussion started by: sureshvaikuntam
1 Replies

6. Programming

help regarding socket programming

i m using sockets for setting up a connection between a server and a client. When the clients gets connected to the server, its ip is conveyed to the server through one of the predefined structures in c library... i save this ip address in an array....1st client's ip address goes to the zeroth... (1 Reply)
Discussion started by: abmxla007
1 Replies

7. Programming

Please help! accept function problems in Socket programming

Hi, I have a client-server socket program. It has been working fine for over a year, but recently it started to show strange behavior.:confused: After the server program runs for a while, it will show in the top command saying it is using lots of CPU, MEM. I assume it means the server code is... (1 Reply)
Discussion started by: natxie
1 Replies

8. Programming

socket accept() keeps looping

I'm using C/ C++ with gcc on Linux. I've a server socket where accept() is called on the socket inside a while() loop. The problem I am facing is that the first call to accept is blocking (i.e., the program waits for the first connection) but as soon as I fork afterwards (so that the child process... (2 Replies)
Discussion started by: jaywalker
2 Replies

9. Programming

socket programming

how to include socket.h in visual studio 2005.. (2 Replies)
Discussion started by: asd123
2 Replies

10. Programming

Looping connect call for a non blocking socket

will there be any unexpected results on looping connect call for a non blocking socket to determine the connection based on error code. I am getting connection unsuccessful intermittently and so wondering whether is the timeout 500 millisec not sufficient or looping connect cause any unexpected. ... (7 Replies)
Discussion started by: satish@123
7 Replies
XkbGetAutoResetControls(3)					   XKB FUNCTIONS					XkbGetAutoResetControls(3)

NAME
XkbGetAutoResetControls - Gets the current values of the auto-reset controls SYNOPSIS
Bool XkbGetAutoResetControls (Display *dpy, unsigned int *auto_ctrls, unsigned int *auto_values); ARGUMENTS
- dpy connection to X server - auto_ctrls specifies which bits in auto_values are relevant - auto_values 1 bit => corresponding control has auto-reset on DESCRIPTION
You can configure the boolean controls to automatically be enabled or disabled when a program exits. This capability is controlled via two masks maintained in the X server on a per-client basis. There is no client-side Xkb data structure corresponding to these masks. Whenever the client exits for any reason, any boolean controls specified in the auto-reset mask are set to the corresponding value from the auto- reset values mask. This makes it possible for clients to "clean up after themselves" automatically, even if abnormally terminated. The bits used in the masks correspond to the EnabledControls control bits. For example, a client that replaces the keyboard bell with some other audible cue might want to turn off the AudibleBell control to prevent the server from also generating a sound and avoid cacophony. If the client were to exit without resetting the AudibleBell control, the user would be left without any feedback at all. Setting AudibleBell in both the auto-reset mask and auto-reset values guarantees that the audi- ble bell will be turned back on when the client exits. XkbGetAutoResetControls backfills auto_ctrls and auto_values with the AutoReset control attributes for this particular client. It returns True if successful, and False otherwise. RETURN VALUES
True The XkbGetAutoResetControls function returns True when it successfully backfills auto_ctrls and auto_values with the AutoRe- set control attributes for this particular client. False The XkbGetAutoResetControls function returns False when it does not successfully backfill auto_ctrls and auto_values with the AutoReset control attributes for this particular client. X Version 11 libX11 1.5.0 XkbGetAutoResetControls(3)
All times are GMT -4. The time now is 02:23 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy