Category : asynchronous

My problem This function is supposed to accept() a connection from a client and return the new file descriptor newfd. The problem is that waiting for a connection freezes the Qt GUI. int tcp_connect(int sockfd) { struct sockaddr_storage client_addr; socklen_t sin_size = sizeof client_addr; int newfd = accept(sockfd, (struct sockaddr *)&client_addr, &sin_size); return newfd; } ..

Read more

I am running several async line traces in unreal, and I want to wait until each of them is complete. Upon completion, I want to use their hit results (data.OutHits). However, upon completion, FTraceDatum still appears to contain its default values (Start and End both point to the origin and the OutHits size is always ..

Read more

I’m trying to write asynchronous code on callbacks and stuck into this error: error: cannot declare field ‘std::_Head_base<3, Callback, false>::_M_head_impl’ to be of abstract type ‘Callback’ note: because the following virtual functions are pure within ‘Callback’ … error: no matching function for call to ‘std::tuple<api_add(int, int, Callback&&)::<lambda(int, int, Callback&&)>, int, int, Callback>::tuple(<brace-enclosed initializer list>)} }; ..

Read more