mIRC Home    About    Download    Register    News    Help

Print Thread
#50469 21/09/03 12:56 AM
Joined: Jan 2003
Posts: 2,125
Q
qwerty Offline OP
Hoopy frood
OP Offline
Hoopy frood
Q
Joined: Jan 2003
Posts: 2,125
This command:
Code:
//tokenize 44 a b c d e f | echo -a $*
either typed in an editbox or executed from within a script, crashes mirc. Sometimes you need to type it twice or more to make it crash, but most of the times once is enough. It doesn't seem to have anything to do with the number chosen for token separator.

#50470 21/09/03 01:05 AM
Joined: Dec 2002
Posts: 1,518
_
Hoopy frood
Offline
Hoopy frood
_
Joined: Dec 2002
Posts: 1,518
i just tested it in mirc 6.03 and 6.1 and one time in each it crashed it without even a warning or error .. just closed the program out. both were completely scriptless versions and one tested on a mirc with several scripts installed.

#50471 21/09/03 01:06 AM
P
pheonix
pheonix
P
what does $* actually do crazy

coz i tried this:

Code:
tidy_trax_2 : !say $* 1 2 3 4 5 6 7 8 9 10
  	tidy_trax_4 : !say 1 2 3 4 5 6 7 8 9 10
  	tidy_trax_4 : $* 1 2 3 4 5 6 7 8 9 10
  	tidy_trax_4 : 1 1 2 3 4 5 6 7 8 9 10
  	tidy_trax_4 : 2 1 2 3 4 5 6 7 8 9 10
  	tidy_trax_4 : 3 1 2 3 4 5 6 7 8 9 10
  	tidy_trax_4 : 4 1 2 3 4 5 6 7 8 9 10
  	tidy_trax_4 : 5 1 2 3 4 5 6 7 8 9 10
  	tidy_trax_4 : 6 1 2 3 4 5 6 7 8 9 10
  	tidy_trax_4 : 7 1 2 3 4 5 6 7 8 9 10
  	tidy_trax_4 : 8 1 2 3 4 5 6 7 8 9 10
  	tidy_trax_4 : 9 1 2 3 4 5 6 7 8 9 10
  	tidy_trax_4 : 10 1 2 3 4 5 6 7 8 9 10

on tidy:TEXT:!say *:#:{
say $eval($2-,2)
}

#50472 21/09/03 02:33 AM
Joined: Feb 2003
Posts: 806
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Feb 2003
Posts: 806
It does a loop, then halts the script.
"<command> $*" calls "<command>" $0 times, each time assigning a $N parameter to it.

alias blah { echo -a -> $* }
/blah a b c d e
-> a
-> b
-> c
-> d
-> e

#50473 21/09/03 02:41 AM
P
pheonix
pheonix
P
ah, thanks smile

#50474 24/09/03 03:16 PM
S
saxon
saxon
S
Strangely for me this crashes 6.03 instantly, But i can do it in 6.1 to my hearts content and it doesn't crash.. I'm on Windows Millenium here.

#50475 24/09/03 03:21 PM
Joined: Feb 2003
Posts: 806
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Feb 2003
Posts: 806
BTW, I was wrong, $* doesn't halt the script.

#50476 24/09/03 03:22 PM
R
r0ck0
r0ck0
R
It worked perfectly in both 6.03 & 6.1 for me.

Quote:
//tokenize 44 a b c d e f | echo -a $*


Actually I tried that just one time and it worked fine.
So I tried it a few minutes later & then again a couple of seconds later and 6.03 & 6.1 crashed, and now it keeps crashing everytime I try it.

Last edited by r0ck0; 24/09/03 03:32 PM.
#50477 24/09/03 03:26 PM
Joined: Feb 2003
Posts: 806
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Feb 2003
Posts: 806
Doesn't crash here. I typed several times.. from a script, it freezed mIRC when called from a loop, though.. but no crash.

(mIRC 6.1, w98SE)

#50478 24/09/03 03:46 PM
S
saxon
saxon
S
Yeah i tried it something like 20 times in 6.1 and it doesn't crash for me. Crashes instantly in 6.03. It must be something do with different hardware or operating systems, no doubt the bug is legitimate...

#50479 24/09/03 11:02 PM
Joined: Feb 2003
Posts: 2,737
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,737
Note this parallel thread, perhaps there's some correlation between these two bugs.

Does it ever crash mIRC on its first use, or only subsequent uses?
Does it ever crash if $0 is greater-than 1?

Neither of these crashes 6.03 or 6.10.
//tokenize 44 a | echo -a $*
//tokenize 44 a b c d e | echo -a $*
This echos the text then produces a GPF in 6.03 on the first try, but does not crash 6.10.
//tokenize 44 a b c d e f | echo -a $*
This produces a GPF in 6.03 without echoing any text, but does not crash 6.10.
//tokenize 44 a b c d e f g | echo -a $*
This produces a GPF in 6.03 AND 6.10, but only echos text in 6.10 before crashing.
//tokenize 44 a b c d e f g h | echo -a $*
And so on.

- Raccoon


Well. At least I won lunch.
Good philosophy, see good in bad, I like!
#50480 27/09/03 03:07 AM
O
Olathe
Olathe
O
Strangely enough, //tokenize 44 a b c d e f | echo 4 -a $* doesn't crash.

#50481 29/09/03 12:24 AM
D
DaveC
DaveC
D
i looked through the help and couldnt find any about $* so maybe im thinking its a unsupported function.

But anyway. I noticed certian things when i was doing it.
such as
alias asd {
echo -a $*
echo -a -#1 $1-
echo -a $*
echo -a -#2 $1-
}
/asd a b c d e f
a
b
c
d
e
f
-#1 a b c d e f
-#2 a b c d e f

seems the second $* doesnt have anything to process, i think $* keeps a running total of what passed parameter its up to.
as
tokenize 32 a b c
echo -a $*
tokenize 32 q w e r t y
echo -a $*

Results in
a
b
c
r
t
y

I believe this command is way to unreliable to use ever!

#50482 30/09/03 07:19 PM
Joined: Feb 2003
Posts: 2,737
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,737
Please see this thread.


Well. At least I won lunch.
Good philosophy, see good in bad, I like!

Link Copied to Clipboard