Closed amoral-pony closed 5 months ago
What do you mean by "I get the requests I sent earlier"? send
returns nothing, so you can't receive anything from it.
In the log you create a TDLib instance, which is closed immediately, because corresponding ClientManager is destroyed.
Is it normal that I send an empty request and TDLib sends an update for updateOption
, updateAuthorizationState
, then repeatedly accepts the updates and closes, even though there is nothing in the program other than sending an empty request. When I tried sending a query with some object and receiving a response via receive()
, the response did not change depending on the query.
TDLib can send updates any time whenever appropriate. It has closed, because the corresponding ClientManager
was destroyed and your app lost ability to send request to it, or receive updates and responses from the instance.
I was sending and receiving requests via the receiveUpdates_()
method, so the ClientManager was not destroyed at that point.
I'm starting to learn TDLib. I have a
receiveUpdates_
method that receives updates and fills in certain fields. I have compiled and run the program several times, sending requests totd_api::getOption(...)
,td_api::close()
e.t.c. Now the situation is worse: when calling, for example,clientManager_->send(clientId_, requestId++, nullptr)
, I get the requests I sent earlier. The tdlib directory did not appear in my working directory. Here is how it looks like:Output:
How do I prevent old requests from being sent?