Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6067423
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T09:36:22+00:00 2026-05-23T09:36:22+00:00

The requirement is to make a C/C++ program that is a chat room. 1,

  • 0

The requirement is to make a C/C++ program that is a chat room.

1, Both the client and server program need no GUI, use command line only. And they only need to run in the same machine, connected with pipes.

2, Use a FIFO queue in a Daemon Process, and users can chat using the Daemon Process at the same time.

3, The Daemon Process refreshes the number of online users and print login/out messages to the clients.

4, Client requires a nick name on start and the server reject when the nick name conflicts.

.

It’s supposed to adapt Processes, Daemon Processes, Pipes, Signals, I/O, Threads to make this program, as much as possible.

Now I’m not familiar with Processes in Linux. Can you show me an Example of operating processes for a chat room, or a simple frame that I can write the functions without worrying the processes.

And any other suggestions about writing this program is welcome!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T09:36:23+00:00Added an answer on May 23, 2026 at 9:36 am

    Sounds like you are being asked to both design and write this program.

    Your question sounds rather like you need to have a client-server architecture (which makes sense) and talks over a pipe (you could equally do the same thing with a socket so you might want to make this layer easy to swap out later)

    So, you need one program that runs in the background once started ( a daemon ) that runs the service listening on a pipe for chat messages and also monitors /var/run/utmp to see who is logged into the machine.

    The daemon could be written as a single-thread process and using select calls to monitor client and the utmp file but since you have the threads requirement you could make each of these two functions be threads, makes your program more complex and harder to debug but who am I to argue.

    You need another program that a user can run to connect to the daemon via a pipe and that you can type messages into or print messages from the daemon. Again, this could be done single-threaded but you might want to split transmit and recieve into threads instead.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a Requirement to make an IMAP client as a Web application I
Requirement : Should update MySQL database with that of MS Sql Server updates which
My requirement is I have server J2EE web application and client J2EE web application.
A requirement for a program I am writing is that it must be able
I have a requirement to build an application that a company can use to
I have a requirement that a Windows Forms C# .NET 2.0 program running in
I have a requirement to make a large amount of code MISRA compliant. First
Requirement is this ... We have our 3 web-applications deployed in RHEL-5 server, we
I'm writing a program that among other things needs to download a file given
I am writing a program that's similar to a shell. Once started up, there's

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.