❔ ContextSwitchDeadlock
Hi - in my windows form program I generate some RSA keys before the program loads, this takes around 2 minutes though and after 60 seconds the program crashes due to taking too long - how would I go about preventing this? I don't know much about threads and stuff
3 Replies
The "long" function is called under "form1_load"
run it on another thread (with
Task.Run
)
show something like a loading icon while generating the keys
idk anything about cryptography but 2 minutes seems like a lotWas this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.