Note that there may be two (or more) lines for one error.
Best to clear it out and read it for each openssl call.
There are no "threads" and if the other library doesn't have enough sense to read (and therefore clear) the queue (errr, dequeue) of messages before and after their openssl calls...
A) That's their problem
B) Look for a new library, because NOT doing that means they aren't writing their code properly.