TCP Broadcast
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Unix and Linux reviews > Free Unix support > Unix Programming > TCP Broadcast




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    TCP Broadcast  
user@domain.invalid


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
05-10-04 10:44 PM

I am writing an application using TCP sockets, I don't know the IP
address of the server and am thinking of using a broadcast to find it.

I am using these examples as a test.
http://www.ecst.csuchico.edu/~beej/...amples/server.c
http://www.ecst.csuchico.edu/~beej/...amples/client.c

How do you modify these so the client will do a broadcast.
I had a guess at using use SO_BROADCAST in programs but it doesn't
appear to change anything.

Thanks
Neil






[ Post a follow-up to this message ]



    Re: TCP Broadcast  
Barry Margolin


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
05-10-04 10:44 PM

In article <c7mmia$rur$1@au-nws-0001.flow.com.au>, user@domain.invalid
wrote:

> I am writing an application using TCP sockets, I don't know the IP
> address of the server and am thinking of using a broadcast to find it.
>
> I am using these examples as a test.
> http://www.ecst.csuchico.edu/~beej/...amples/server.c
> http://www.ecst.csuchico.edu/~beej/...amples/client.c
>
> How do you modify these so the client will do a broadcast.
> I had a guess at using use SO_BROADCAST in programs but it doesn't
> appear to change anything.

Read the "Broadcasting" chapter of "Unix Network Programming, Vol.1"

--
Barry Margolin, barmar@alum.mit.edu
Arlington, MA
*** PLEASE post questions in newsgroups, not directly to me ***





[ Post a follow-up to this message ]



    Re: TCP Broadcast  
user@domain.invalid


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
05-10-04 10:44 PM



Barry Margolin wrote:

> In article <c7mmia$rur$1@au-nws-0001.flow.com.au>, user@domain.invalid
> wrote:
>
> 
>
>
> Read the "Broadcasting" chapter of "Unix Network Programming, Vol.1"
>

I Don't have that book!  Is there an online source of info.








[ Post a follow-up to this message ]



    Re: TCP Broadcast  
Barry Margolin


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
05-10-04 10:44 PM

In article <c7msba$u4a$1@au-nws-0001.flow.com.au>, user@domain.invalid
wrote:

> Barry Margolin wrote:
> 
>
> I Don't have that book!  Is there an online source of info.

If you're serious about network programming, you really should get that
book.  It's a comprehensive source of answers to many questions about
network programming.

--
Barry Margolin, barmar@alum.mit.edu
Arlington, MA
*** PLEASE post questions in newsgroups, not directly to me ***





[ Post a follow-up to this message ]



    Re: TCP Broadcast  
user@domain.invalid


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
05-12-04 03:34 AM



Barry Margolin wrote:
> In article <c7msba$u4a$1@au-nws-0001.flow.com.au>, user@domain.invalid
> wrote:
>
> 
>
>
> If you're serious about network programming, you really should get that
> book.  It's a comprehensive source of answers to many questions about
> network programming.
>

I have found the answer, after doing a search and looking though a lot
of WEB pages, I found a hint that I needed to use UDP instead.  After
some experiments I got it to work.






[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 05:18 AM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register