UNIX/Linux Programming - December 2018

How to speed up program?
 
I’m supposed to measure the time in seconds but not constantly access it. I’m supposed to set a new alarm each time a previous one goes off. My program comp...
[2 replies] Last: > However, my code is too slow. Well having sleep(1) in the middle of ... (by salem c)
trouble with race conditions?
 
I'm supposed to allocate a shared memory segment that contains an integer variable and set it to zero. This creates a clone that will start adding 1 to the shar...
[3 replies] Last: Line 12: SMHSZ is redefined from the line before. Why? Line 29: sbuff ... (by dhayden)
linking xcode with Buddy library
 
hello i'm trying to linking buddy library with xcode c++ to use it .. i have dependency problem i do not know way ! i downloaded the library from git then i...
[no replies]
TCP client terminating abruptly without any error message
 
I have created a TCP server-client application in C++, where client first sends login request and server checks the credentials and if they are proper then serv...
[1 reply] : What sort of error checking, recovery, retry do you have? Are you ass... (by salem c)
by tutu10
Kickstart Config file not working on the exam
 
I had issues with the installation of a vm. I suspect that there were issues with the kickstart configuration file. I did these exact steps as taught by the sel...
[1 reply] : Did you really use example.com on your command line, or did you substi... (by salem c)
Get the sum of only a specific group of elements in a vector
 
Hello, I have a sorted vector and my operation is to get the sum, but only for the group of numbers that have more than 4 elements and difference less than 3. ...
[4 replies] Last: This is brilliant. I am extremely thankful for the time and interest y... (by AkshayMalige)
take a baby step in mutex programming, result is unconclusive
 
Here is my code I "designed". 1. Mutex is a global var. 2. CONFIG_THREAD_COUNT number of threads are launched with hello() function target. 3. In hello() fu...
[16 replies] Last: I understand what you're talking, but I've no idea what you're taking.... (by salem c)
Printing any box drawing character permanently kills wcout
 
There's some weird issue with my program that's been torturing me for like 2 hours. This is my last day and I need to get this done ASAP, and I don't know anyon...
[16 replies] Last: Switched to std::wprintf and everything is fine now. Sorry, lol... (by LoganDark)
List getting corrupted
 
4 threads are runing this function processthread and i am taking a lock while adding at g_cProcessMutex,but sometimes list.pop_back() gives SIGABORT,what would ...
[2 replies] Last: Extending the lock to also cover g_cProcessList.empty() as well. I t... (by dhayden)
  Archived months: [nov2018] [jan2019]

This is an archived page. To post a new message, go to the current page.