Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD Beta Forum
Vijilante
SubAdmin


Joined: 18 Nov 2001
Posts: 5182

PostPosted: Fri Sep 28, 2007 11:37 pm   

[2.04] #THREAD #STOP lockup combo
 
This always produces a lockup.

1. Launch CMud
2. Press ESC to close Sessions Window
3. At the command line type '#THREAD untitled' and press ENTER
4. Second command entry '#STOP untitled' and press ENTER

Neither command by themselves produces a lockup, but the 2 of them done in that sequence are deadly.
_________________
The only good questions are the ones we have never answered before.
Search the Forums
Reply with quote
Zugg
MASTER


Joined: 25 Sep 2000
Posts: 23379
Location: Colorado, USA

PostPosted: Fri Sep 28, 2007 11:40 pm   
 
Boy, you really are evil. aren't you Twisted Evil

Heh, yeah, telling it to stop/close the main thread (which is the one you always have by default) would definitely cause problems. Do you get the same problem if you do a #THREAD and find the thread ID number and then use '#STOP number' giving the ID number?

I'll add this to the bug list, but I'm not sure that this one really has any effect on "normal" operations.
Reply with quote
Vijilante
SubAdmin


Joined: 18 Nov 2001
Posts: 5182

PostPosted: Fri Sep 28, 2007 11:53 pm   
 
Using '#STOP 1' as the first command entered causes the same lockup.

However, when you do '#STOP untitled' as the first command it doesn't cause a lockup. You can even hit that command many times or put it in a #LOOP and it doesn't cause a problem. Using the name only causes a problem when the #THREAD command precedes it.

I think the bugs are:
1. incosistent behavior
2. main thread should refuse #STOP
_________________
The only good questions are the ones we have never answered before.
Search the Forums
Reply with quote
Thinjon100
Apprentice


Joined: 12 Jul 2004
Posts: 190
Location: Canada

PostPosted: Fri Sep 28, 2007 11:56 pm   
 
To chime in and cross-reference this with my own post... When I #STOP the thread that's apparently sourced from my capture window:
Code:

  60             wiznet               stopped              Trigger: capfailhelp : #COL $cc99cc     

The next time a trigger in that window fires, my CMud crashes.
_________________
If you're ever around Aardwolf, I'm that invisible guy you can never see. Wizi ftw! :)
Reply with quote
Vijilante
SubAdmin


Joined: 18 Nov 2001
Posts: 5182

PostPosted: Sat Sep 29, 2007 12:41 am   
 
Just for giggles I also caused the same lockup by doing these two commands in sequence
#THREAD abc
#STOP abc

So this would explain why just doing '#STOP untitled' by itself caused nothing. The main thread has no name until that initial #THREAD command. I have to correct myself; behavior is consitent. Killing the main thread is evil. Twisted Evil

As for normal operations, I believe there are still some context issues, and it is conceivable to me that someone would use '#STOP %threadid()' as an abort in a script. If the context or script usage is wrong then the main thread can get stopped. No matter what that stoppage needs to be prevented.
_________________
The only good questions are the ones we have never answered before.
Search the Forums
Reply with quote
Zugg
MASTER


Joined: 25 Sep 2000
Posts: 23379
Location: Colorado, USA

PostPosted: Sat Sep 29, 2007 1:38 am   
 
Quote:
Using the name only causes a problem when the #THREAD command precedes it.

Yes, as you noticed, the main thread has no title until you use the #THREAD command to name it. When a thread doesn't have any title, the #THREAD command shows the name of the window that created the thread as it's name.

The proper way to "stop" the current thread is to use #ABORT. But yes, I need to prevent the main thread of a window/module from being stopped.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD Beta Forum All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net