We help IT Professionals succeed at work.
Get Started

Threads inside DLL

1,524 Views
Last Modified: 2013-12-14
Dear Experts,

I'm an Adobe Acrobat plug-in developer, and I'm stack here with some problem related to DLLs, I would appreciate your help (with points of course... :) ).

The plug-in works as DLL.
Inside that DLL, I'm having a thread I'm creating for some kind of a message loop.
In that thread, when I get signaled, I'm running a function that I have that handles the message.
The problem I have is that in many time this function cause Acrobat to crash.
Now, I know the problem is with Acrobat but I don't have the source of it, and I have to bypass it.

When I'm trying to run the code directly and not inside the thread the code runs with no problems.

My question is: is there any difference in execution for a code that runs inside / outside a dll?

I'm working with Visual Studio 2003 .NET ("c++")
The thread is created with AfxBeginThread

Many thanks,
Doron
Comment
Watch Question
Commented:
This problem has been solved!
Unlock 3 Answers and 10 Comments.
See Answers
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE