I can reproduce the problem, which is in fact not a problem.
I used this code :
Code:
#_DEFAULT.PROPERTIES OFF

[start]

[CONST]
SJISSPEC=$mircdir $+ sjis-0208-1997-std.txt

#_DEFAULT.PROPERTIES END

ALIAS __SJISspec { return $readini($script,CONST,SJISSPEC) }

ALIAS DEC2HEX {
  var %pad = $len($base($$1,10,16))
  if (2 \\ %pad) { %pad = %pad + 1 }

  if ($isid) { return $base($$1,10,16,%pad) }
  elseif ($1 isnum) { echo -aspe 0x $+ $base($$1,10,16,%pad) }
}
ALIAS HEX2DEC {
  if ($left($1,2) == 0x) || ($left($1,2) == U+) { tokenize 32 $right($1,-2) }
  if ($isid) { return $base($$1,16,10,1) }
  else { echo -aspe  $base($$1,16,10,1) }
}

alias import_sjis {
  if ($hget(sjis)) hfree sjis
  hmake sjis 10000
  fopen sjis $qt($__SJISspec)
  var %z
  while (!$fopen(sjis).eof && !$ferr) {
    tokenize 09 $fread(sjis)
    inc -s %z
    if ($0 > 2) { var %sjis = $1, %utfc = $2, %desc = $3- }
    else { var %sjis = $1, %utfc, %desc = $2- }

    ; if ($+($#,*) iswm %sjis) continue
    if ($hex2dec(%sjis) < 128) continue
    echo -s %desc - %sjis - %utfc - $feof - $ferr -
    if (<doublebytes> isin %desc) { /hadd sjis $hex2dec(%sjis) <doublebytes> }
    elseif (<cjk> isin %desc) { /hadd sjis $hex2dec(%sjis) $hex2dec(%utfc) $chr($hex2dec(%utfc)) }
    elseif ($left(%utfc,2) == U+) { /hadd sjis $hex2dec(%sjis) $hex2dec(%utfc) $chr($hex2dec(%utfc)) }
  }
  :error
  if ($error) echo -s Error : $error
  fclose sjis
}
First note that there's a empty line in your big file at the end.
This code will show you that in mIRC 6.35, $feof (or $fopen().feof) is 1 after $freading the last non empty line, which cause the while loop to stop.
In mIRC 7.17, it correctly read the next line, which is $null and in that case mIRC halt because of a $null value and the use of $$.
The commented line in the code is odd, $# doesn't exist which cause an error if you have that warning option enabled, or a line like "if (* iswm %sjis) continue"..


#mircscripting @ irc.swiftirc.net == the best mIRC help channel