Initializing/Terminating PDFNet from Native C++

Q: I implemented PDFNetC SDK in our application which is Native C++,
I use it as two singletons: one for merge uses and the second for
print uses, in 2 different threads.

Functionality It works well, but when we exit the application the
application crashes. Note that PDFNet::Initialize() and
PDFNet::Terminate() are been ran 2 times. Do you have any idea?
Is it OK to run PDFNet::Terminate() 2 times a process?

A: You should call PDFNet::Initialize() and PDFNet::Terminate() only
once per process session. A typical location would be in your
application startup function (i.e. main() ). Alternatively you could
skip calling PDFNet::Terminate() altogether (since it is used to
release resources which would be released anyways when the process is