Morten_rn_dk
(Just in Town)
2014-12-03 09:34 AM
Troubles with ascan

Having some troubles with ascan - version 4.61 and version 4.64 of kix32.exe behaves differently

$a="1","","2","3","","5","6","7","8","9","10"
? Join( AScan($a,"9",,,3) , ",")

Version 4.61 of Kix32.exe Returns : 9 (correct)
Version 4.64 of Kix32.exe Returns : 1,4,9 (wrong)


AllenAdministrator
(KiX Supporter)
2014-12-03 03:51 PM
Re: Troubles with ascan

I was not able to reproduce the problem. Here is your script modified to show a little more info:

 Code:
? @kix
$a="1","","2","3","","5","6","7","8","9","10",19,"9"
? "Return All Exact Matches:" + Join( AScan($a,"9",,,2) , ",") 
? "Return All Instr Matches:" + Join( AScan($a,"9",,,3) , ",") 


4.64 returns
 Code:
4.64
Return All Exact Matches:9,12
Return All Instr Matches:9,11,12


4.62 returns the same


LonkeroAdministrator
(KiX Master Guru)
2014-12-03 04:16 PM
Re: Troubles with ascan

I was able to reproduce the issue with a 4.64 and with an 4.65 alpha build.
this is indeed a bug with ascan() and I think it has been discussed before...

Allen your script with 4.64 produces:
 Code:
Return All Exact Matches:9,12
Return All Instr Matches:1,4,9,11,12


AllenAdministrator
(KiX Supporter)
2014-12-03 04:22 PM
Re: Troubles with ascan

I'm using Win 8.1 x64 for what it's worth.

LonkeroAdministrator
(KiX Master Guru)
2014-12-03 04:24 PM
Re: Troubles with ascan

and Ruud is using VS2013. yea, might be microsoft messing things up again.

will see once he sees this.


AllenAdministrator
(KiX Supporter)
2014-12-03 04:26 PM
Re: Troubles with ascan

Until the bug gets narrowed down, Morten, would the Exact search work?

Henriques
(Fresh Scripter)
2014-12-04 12:38 AM
Re: Troubles with ascan

This is strange, I agree for the results with Allen, I combined the scripts of Morten_rn_dk and Allen with the following result;

 Code:
If @ONWOW64
    $RESULT = SetOption("WOW64FileRedirection", "On")
    $RESULT = SetOption("WOW64AlternateRegView", "On")
Else
    $RESULT = SetOption("WOW64FileRedirection", "Off")
    $RESULT = SetOption("WOW64AlternateRegView", "Off")
EndIf
Cls

? 'OS + patchlevel = ' + RTrim(@PRODUCTTYPE + ' ' + @DOS + ' ' + @CSD) + '.'
? "Kix Version = " + @KIX + @CRLF

$A="1","","2","3","","5","6","7","8","9","10"
? "Morten_rn_dk"
? Join( AScan($A,"9",,,3) , ",")
? "-------------------------------------------------"
? "Allen"
$A="1","","2","3","","5","6","7","8","9","10",19,"9"
? "Return All Exact Matches:" + Join( AScan($A,"9",,,2) , ",")
? "Return All Instr Matches:" + Join( AScan($A,"9",,,3) , ",")


Result;
 Code:
OS + patchlevel = Windows 8.1 Professional Edition 6.3.
Kix Version = 4.64

Morten_rn_dk
9
-------------------------------------------------
Allen
Return All Exact Matches:9,12
Return All Instr Matches:9,11,12



LonkeroAdministrator
(KiX Master Guru)
2014-12-04 03:27 AM
Re: Troubles with ascan

Nice. So indeed something in c++ is broken in VS2013.

Glad to tell I have never used it myself. Hate the new look BAD


Ruud van Velsen
(Hey THIS is FUN)
2015-07-20 03:30 PM
Re: Troubles with ascan

Thanks for the report. I've checked this, and am not able to reproduce the issue, either with 4.64 or the latest build.

If anyone thinks this is still an issue, please post additional steps/info to repro.

Ruud


AllenAdministrator
(KiX Supporter)
2015-07-21 04:08 PM
Re: Troubles with ascan

Although no one said it out right, I got the impression it was OS related. I could not reproduce the error using Win 8.1 x64.

Lonk, what OS are you on?


LonkeroAdministrator
(KiX Master Guru)
2015-07-21 04:26 PM
Re: Troubles with ascan

win7 64bit.

Ruud van Velsen
(Hey THIS is FUN)
2015-07-22 01:42 PM
Re: Troubles with ascan

... and there you have it...

Amazingly, this issue turns out to be specific to Win7...

Don't understand how or why exactly, but the runtime function involved operates ever so slightly different on Win7.

Just managed to repro on a Win7 box, and have added a workaround for this in the upcoming build.

As always: thanks for the report/support!!

Ruud


AllenAdministrator
(KiX Supporter)
2015-07-22 03:45 PM
Re: Troubles with ascan

Dude. Nice work! \:\)

LonkeroAdministrator
(KiX Master Guru)
2015-07-24 04:20 AM
Re: Troubles with ascan

indeed. and Ruud, I bet you can thank either the security update folks or whoever decided that vista was ready to ship... either or, they made a mistake and we all still suffer for it.