Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7843923
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T16:42:52+00:00 2026-06-02T16:42:52+00:00

I am doing a project where I am loading several assemblies during runtime, for

  • 0

I am doing a project where I am loading several assemblies during runtime, for each of those assemblies I use reflection to find some specific classes, instantiate them and calling their methods. All this is working fine, but for some of the calls the process encounters a stack overflow which terminates my entire program. I don’t have any control over the source code of the assemblies I am loading so I cant change the code I’m executing.

What I have tried to solve the problem:

  1. I assign a thread to do the invocation of the methods and tried to
    abort the thread after a timeintervall(I know that this is bad
    practice but I cant change the code to terminate friendly). This
    however doesn’t work, I think the thread is to busy “stackoverflowing”
    to handle the Abort-call.

  2. Ive tried reducing the actual memory the thread has access to, this is not even a solution because you cant catch the stackoverflow-exception so my program terminates anyway (just quicker)

Questions:

  1. Can a thread be to busy to be aborted? Is there some way to abort a thread that is having this behaviour?
  2. How can we call code (that we don’t have any control over) in a good way?

Thanks in advance!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T16:42:53+00:00Added an answer on June 2, 2026 at 4:42 pm

    The recommended procedure in case of “opaque code” is to actually fork a new process and start it. That way you gain two benefits:

    1. If it fails by itself, it’s isolated and won’t take your main application down as well.
    2. You can safely kill it and it won’t cause as much trouble as an aborted thread.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Im doing a project where Alice and Bob send each other messages using the
I'm currently doing a project in C# working with windows forms. During the course
I'm doing a project using ActionScript 2 where I'm loading in text from an
I'm doing some research for a project that I might be doing soon, and
I am doing a project in which I am loading a table view with
I am doing some significant refactoring and feature-adding on a project, and have just
I'm currently doing some optimization work on a large web project. I'm already doing
I'm doing my first project with jquery: My site will have some tabs: 1.
I am doing project euler question 33 and have divised a refactor to solve
I am doing project in cakephp . I want to write below query in

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.