Sponsored Content
Full Discussion: Basic question about sockets
Special Forums IP Networking Basic question about sockets Post 302737577 by vbe on Thursday 29th of November 2012 08:15:05 AM
Old 11-29-2012
Not sure I understood:
Is it you want only one connection? meaning that all other are refused till disconnect (single user app.) ? Or is it you have problems dealing with concurrent access e.g. when 2 people try to connect at the same time (in sequence , no issue...)
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

basic question

I have some basic doubts. Can someone clarify in this forum? 1)if then eval ' tset -s -Q -m ':?hp' ' else eval ' tset -s -Q ' what does it exactly mean in .profile? 2) what are 'nobody' and 'noaccess' usernames in /etc/passwd file. ... (3 Replies)
Discussion started by: asutoshch
3 Replies

2. UNIX for Dummies Questions & Answers

basic question

hey...when i type who...what does "pts" field mean??? eg pts 0 etc (1 Reply)
Discussion started by: urwannabefriend
1 Replies

3. Programming

sockets question

I'm new to sockets programming and I have a few questions: Is the a maximum limit that you can use for the send and receive buffers via a call to setsockopt()? Does it differ on different OSs? If it does, how do I find out the max limit? What is the advantage to setting the buffers to be... (1 Reply)
Discussion started by: jalburger
1 Replies

4. Programming

sockets question again

I apologize if this seems like a repeat post, but I never got a clear answer (this isn't a criticism, it's possible I'm not being clear enough)....I'm attempting to enlarge the socket buffers for a udg socket, but it seems that no matter how large I attempt to set the buffer with setsockopt( ) ... (3 Replies)
Discussion started by: jalburger
3 Replies

5. UNIX for Dummies Questions & Answers

Very Basic Question

How to know if my AIX 5.2 is running at 64bits? THANKS (5 Replies)
Discussion started by: GermanSkull
5 Replies

6. UNIX for Dummies Questions & Answers

Really basic question....

Hello all. Let me start off by saying I know a little more then it seems by me asking this question... here goes I have an old 486 box and I want to start messing around with unix. I've been taking classes for 3 or 4 years in c programming in unix, so I am used to the commands and such, but I... (1 Reply)
Discussion started by: robherms
1 Replies

7. HP-UX

Basic OS question

Could someone tell me the command to find out the OS version which will give 12 character not the 9 characters(which is usually machine id). uname -i gives machine id and uname -a is more comprehensive way to look. Thanks! (4 Replies)
Discussion started by: catwomen
4 Replies

8. Shell Programming and Scripting

basic question

hi, I have a basic question,, i am in a directory called /intas/OCU_3.9.1/sbin ocuut1@france>mv itsa_tcs itsa_tcs_old mv: itsa_tcs_old: rename: Permission denied i am logging as the owner of the file. when i am doing this i am getting the above error of permission denied. I know... (3 Replies)
Discussion started by: namishtiwari
3 Replies

9. Shell Programming and Scripting

basic nc question

i'm doing this in one terminal: nc -lu 7402 and it appears to start listening properly, then in another i do this: echo "hello" | nc -u localhost 7402 and nothing happens on the listening terminal - what am i doing wrong? thanks. (7 Replies)
Discussion started by: peterworth
7 Replies

10. Programming

Sockets select() question

Hello everyone. I have a question regarding select() function. Imagine i had passed a fd_set* as the readfds parameter. Can i add some fd to the fd_set, using FD_SET, while the thread is blocked in the select call(obviously from another thread), and will that select call monitor those fd, even if... (2 Replies)
Discussion started by: adadon
2 Replies
t_accept(3xti)															    t_accept(3xti)

Name
       t_accept - accept a connect request

Syntax
       #include <xti.h>

       int t_accept(fd, resfd, call)
       int fd;
       int resfd;
       struct t_call *call;

Arguments
       fd	 Identifies the local transport endpoint where the connect indication arrived.

       resfd	 Specifies the local transport endpoint where the connection is to be established.

       call	 Contains information required by the transport provider to complete the connection.

		 The Call argument points to a t_call structure that contains the following members:
		 struct netbuf addr;
		 struct netbuf opt;
		 struct netbuf udata;
		 int sequence;

		 In call, the members have the following meanings:

		 addr	     Specifies the address of the caller.

		 opt	     Indicates any protocol-specific parameters associated with the connection.

		 udata	     Points to any user data to be returned to the caller.

		 sequence    Is the value returned by that uniquely associates the response with a previously received connect indication.

Description
       A  transport  user  issues  this function to accept a connect request. A transport user can accept a connection on either the same, or on a
       different local transport endpoint than the one on which the connect indication arrived. Before the connection can be accepted on the  same
       endpoint  (resfd==fd),  the user must have responded to any previous connect indications received on that transport endpoint by means of or
       Otherwise, fails and sets t_errno to [TBADF].

       If a different transport endpoint is specified (resfd!=fd), the endpoint must be bound to a protocol address (if it is the same, qlen  must
       be set to 0) and must be in the T_IDLE state before the is issued.

       For  both  types  of endpoints, fails and sets t_errno to [TLOOK] if there are connection indications, (for example, connect or disconnect)
       waiting to be received on that endpoint.

       The values of parameters specified by opt and the syntax of those values are protocol-specific.	The  udata  argument  enables  the  called
       transport  user	to send user data to the caller and the amount of user data must not exceed the limits supported by the transport provider
       as returned in the connect field of the info argument of or If the len field of udata is zero, no data is sent to the caller.

       All the maxlen fields are meaningless.

       ----------------------------------------------
       Parameters	    Before Call   After Call
       ----------------------------------------------
       fd		    x		  /
       resfd		    x		  /
       call->addr.maxlen    /		  /
       call->addr.len	    x		  /
       call->addr.buf	    ?(?)	  /

       call->opt.maxlen     /		  /
       call->opt.len	    x		  /
       call->opt.buf	    ?(?)	  /
       call->udata.maxlen   /		  /
       call->udata.len	    x		  /
       call->udata.buf	    ?(?)	  /
       call->sequence	    x		  /
       ----------------------------------------------

Return Values
       Upon successful completion, a value of 0 is returned. On failure,  a value of -1 is returned, and t_errno is set to indicate the error.

Diagnostics
       On failure, t_errno is set to one of the following:

       [TBADF]		   The file descriptor fd or resfd does not refer to a transport endpoint, or the user is illegally accepting a connection
			   on the same transport endpoint on which the connect indication arrived.

       [TOUTSTATE]	   The	function  was  issued  in the wrong sequence on the transport endpoint referenced by fd, or the transport endpoint
			   referred to by resfd is not in the appropriate state.

       [TACCES] 	   The user does not have permission to accept a connection on the responding transport endpoint or to use  the  specified
			   options.

       [TBADOPT]	   The specified options were in an incorrect format or contained illegal information.

       [TBADDATA]	   The specific amount of user data was not within the bounds allowed by the transport provider.

       [TBADADDR]	   The specified protocol address was in an incorrect format or contained illegal information.

       [TBADSEQ]	   The specified sequence number was invalid.

       [TLOOK]		   An asynchronous event has occurred on the transport endpoint referenced by fd and requires immediate attention.

       [TNOTSUPPORT]	   This function is not supported by the underlying transport provider.

       [TSYSERR]	   A system error has occurred during execution of this function.

See Also
       t_connect(3xti), t_getstate(3xti), t_listen(3xti), t_open(3xti) , t_optmgmt(3xti), t_rcvconnect(3xti)

																    t_accept(3xti)
All times are GMT -4. The time now is 02:40 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy