mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: May 2007
Posts: 37
C
Ameglian cow
OP Offline
Ameglian cow
C
Joined: May 2007
Posts: 37
Noticed a bug with the /bwrite feature of mIRC. When trying to /bwrite non-evaluated plain-text or a variable starting with the character "%", it will always evaluate it and treat it as a variable.

Code:
//bwrite file -1 -1 $(%0D%0A,0)

Code:
//var %x = % $+ 0D%0A | bwrite file -1 -1 %x


returns:
* /bwrite: invalid parameters

Note: Using version 6.2

Last edited by Chessnut; 23/05/07 04:45 PM.
Joined: Jan 2003
Posts: 2,523
Q
Hoopy frood
Offline
Hoopy frood
Q
Joined: Jan 2003
Posts: 2,523
It looks like a side-effect of /bwrite's ability to treat %* tokens (in the evaluated string) as variables. I'm not sure why /bwrite does that, it might be a legacy thing, but I don't think it's of much use now: bwrite file S N %var will first evaluate %var and then write the first N bytes of the result in 'file' anyway. I'd rather see this functionality removed altogether.


/.timerQ 1 0 echo /.timerQ 1 0 $timer(Q).com
Joined: Mar 2007
Posts: 60
S
Babel fish
Offline
Babel fish
S
Joined: Mar 2007
Posts: 60
Why, hello there Chessnut smile This does seem a bit weird. I think as well that the whole feature of that should disappear. It doesn't seem to have much use. Fixing the bug would be just as fine too.

Talk to you later on IRC Chess ;P


"In order to succeed, your desire for success should be greater than your fear of failure."
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Originally Posted By: Spitfire3292
I think as well that the whole feature of that should disappear. It doesn't seem to have much use.


Maybe not to you, but it has use to others.

Joined: Jan 2003
Posts: 2,523
Q
Hoopy frood
Offline
Hoopy frood
Q
Joined: Jan 2003
Posts: 2,523
Can you mention an example where this would be useful?


/.timerQ 1 0 echo /.timerQ 1 0 $timer(Q).com
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Well I myself don't use /bwrite but I've seen a few scripts that have used it.


Link Copied to Clipboard