LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 03-24-2008, 08:42 PM   #1
lrios
Member
 
Registered: Mar 2008
Location: Arg
Distribution: Cent0S
Posts: 48

Rep: Reputation: 15
chat tcp in C


Hi,

Ok, so I am writing my first "real" chat program application(in c).

any other ideas on how to it must be implements a thread in a nice way
it must be a multi-thread. in other words one thread per client.


So i might do all three things:


-server.c, client.c and ..?

-one nick per client(also the nick can't be repeats)

-Could I used recv() and send() functions?

-Handle signal

Which greats ideas can be useful of this kind of program. I hope in your experiences ideas
 
Old 03-24-2008, 09:09 PM   #2
Uncle_Theodore
Member
 
Registered: Dec 2007
Location: Charleston WV, USA
Distribution: Slackware 12.2, Arch Linux Amd64
Posts: 896

Rep: Reputation: 71
I think you should read this article. It contains pretty much all you need with nice examples. http://beej.us/guide/bgnet/
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
is there a prog like gaim that has voice chat, chat to groups, and webcam support? kublador Linux - Software 3 07-08-2008 07:53 AM
how to block yahoo chat & gmail chat with squid sunlinux Linux - Networking 1 08-10-2007 09:33 AM
Linux change TCP kernel Parameter for TCP DELAY ACK TICKS linux_mando Linux - Networking 5 08-22-2006 08:20 AM
Woody 3.0 Open Ports 1470/tcp/uaiact 1518/tcp/vpvd What for?How can I remove them? alexxxis Debian 5 07-05-2004 05:18 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 06:44 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration