So I am initializing the FDS but the program I guess stands in an infinite loop at wait_for_fds_ready():
This is not working. At the moment I have given a delay of 300ms and then do the rest of the initialization but I feel the process is not safe enough.
Let me know if further information is required.