Computers and Technology

What is wrong with this code? I cannot get the port to connect to the socket at all. When I enter a port number the client does nothing. Instructions:Implementing doServer(int listenFd) (10 Points):doServer() should have a loop in which it waits for a client to connect to listenFd. When a client does, it should:malloc() enough memory for 2 integersput the file descriptor from accept() in one of those spacesput the value of threadCount in the other space, and increment threadCountMake a detached thread to handle this new client. I called my function handleClient(), but you may call yours whatever. Pass the address of your malloc()-ed array. The loop should then go back for another accept().void* handleClient(void* vPtr) (10 Points):(Or whatever you call your function that runs a thread for the client.)The thread id and the file descriptor are passed, but they come in as a void* pointer. Use another pointer to cast back to int*Save the file descriptor and thread number in local varsfree() the memoryPrint the thread number and do a loop

answer
Answers: 3

Other questions on the subject: Computers and Technology

image
Computers and Technology, 21.06.2019 22:00, savannahckatz
Business professionals of america, and future business leaders of america – phi beta lambda are both open to business students at which levels? check all that apply. elementary school middle school high school college
Answers: 1
image
Computers and Technology, 22.06.2019 03:30, brin1021
Jessie has received a contract to build a real-time application for a baker. however, the baker doesn't want to invest too much money. his only requirement is that he wants the customers to know which cupcakes are available at what time and in what quantity. so his core requirement is that the details of product should be in real time. what platform can jessie use to develop this application?
Answers: 1
image
Computers and Technology, 22.06.2019 14:40, Kathryn014
You are working with a professional edition organization. they wish to install the expense tracker which requires the use of 4 custom tabs, 3 custom objects, and one custom app. if the company is already using 4 applications, 36 custom objects, and 7 custom tabs, what will happen when they try to install expense tracker?
Answers: 1
image
Computers and Technology, 22.06.2019 17:40, math31343
Gabe wants to move text from one document to another document. he should copy the text, paste the text, and open the new document highlight the text, select the cut command, move to the new document, make sure the cursor is in the correct location, and select the paste command select the save as command, navigate to the new document, and click save highlight the text, open the new document, and press ctrl and v
Answers: 1
Do you know the correct answer?
What is wrong with this code? I cannot get the port to connect to the socket at all. When I enter a...

Questions in other subjects: