Sign in to follow this  
Followers 0
Nugit

IniWrite + FileMove = files corrupted

7 posts in this topic

Hello to the whole AutoIT communauty,

I met a strange issue yesterday with running a installation script I made. In this script, I'm just doing a simple 'IniWrite' call in a file just after, I rename the file using the 'FileMove' function.

Nothing really hard to me and it's works perfectly on several computers with Windows2000 and Windows XP.

But a friend of mine is running WindowsME and he got totally corrupted files after running the same script. The modified files are around 100 lines long and after the script, some of them were only 5 or 10 lines long stopping just after the modified lines with the 'IniWrite' call.

In my mind, it seems like a problem of buffer flush on the 'IniWrite' function (or the Windows one most probably) but I would be happy to know if a workaround exists. I looked for that on the forum but I can't find an answer :">

Thank you in advance for your answers. Best regards

Share this post


Link to post
Share on other sites



Hello to the whole AutoIT communauty,

I met a strange issue yesterday with running a installation script I made. In this script, I'm just doing a simple 'IniWrite' call in a file just after, I rename the file using the 'FileMove' function.

Nothing really hard to me and it's works perfectly on several computers with Windows2000 and Windows XP.

But a friend of mine is running WindowsME and he got totally corrupted files after running the same script. The modified files are around 100 lines long and after the script, some of them were only 5 or 10 lines long stopping just after the modified lines with the 'IniWrite' call.

In my mind, it seems like a problem of buffer flush on the 'IniWrite' function (or the Windows one most probably) but I would be happy to know if a workaround exists. I looked for that on the forum but I can't find an answer :">

Thank you in advance for your answers. Best regards

Which version of AutoIt was used?

Share this post


Link to post
Share on other sites

Hello,

sorry for the lack of precision :

I'm using the 3.1.1 version of AutoIT. The number of files modified is around 3500 files and when the problem occured, every files were corrupted. But as I said, only on this particular computer.

Best regards

Share this post


Link to post
Share on other sites

Hello,

sorry for the lack of precision :

I'm using the 3.1.1 version of AutoIT. The number of files modified is around 3500 files and when the problem occured, every files were corrupted. But as I said, only on this particular computer.

Best regards

Don't be sorry, I was just thinking if I did regression on the last beta.

Knowing it is the official release I am perplex as I don't think we did modification in this area to correct something.

Could that be a Virus? :">

Share this post


Link to post
Share on other sites

Thank you for your answer.

Of course, I can't be sure because my friend is living 2000kms away from me but in general, he's very careful with his computer. So, I'd be doubtful on a virus.

In fact, my problem is that this script should be released for more than 100000 people in few days so I can't take the risk of course if all WindowsMe users met the problem.

I've a workaround : modifying the files on my computer, deleting the old ones on users computers and then put my new files in replacement. So, I'm not worrying really but I like knowing the explanations of my problems :mad2:

By the way, I discovered another bug in IniReadSection function (most probably the Windows function too) and only on WindowsMe. ;)

In a INI file, the section name was this one : "[ CONTROLS ]" with trailing and leading space chars. When calling the IniReadSection function with only "CONTROLS" for the section name, the function answers the section is empty. Once again, only WindowsMe has the problem. WinXP and Windows2000 are working perfectly.

It's not really a bug because the section name is wrong but it's funny to see those different behaviours in quite common functions of Windows. :P

Once again, thank you for your support.

Guillaume

Share this post


Link to post
Share on other sites

Thank you for your answer.

Of course, I can't be sure because my friend is living 2000kms away from me but in general, he's very careful with his computer. So, I'd be doubtful on a virus.

In fact, my problem is that this script should be released for more than 100000 people in few days so I can't take the risk of course if all WindowsMe users met the problem.

I've a workaround : modifying the files on my computer, deleting the old ones on users computers and then put my new files in replacement. So, I'm not worrying really but I like knowing the explanations of my problems :mad2:

By the way, I discovered another bug in IniReadSection function (most probably the Windows function too) and only on WindowsMe. ;)

In a INI file, the section name was this one : "[ CONTROLS ]" with trailing and leading space chars. When calling the IniReadSection function with only "CONTROLS" for the section name, the function answers the section is empty. Once again, only WindowsMe has the problem. WinXP and Windows2000 are working perfectly.

It's not really a bug because the section name is wrong but it's funny to see those different behaviours in quite common functions of Windows. :P

Once again, thank you for your support.

Guillaume

Can you PM me a small reproduction script so I can try it on a WindowsME when I found one?

Thanks

Good luck with so many users :oops:

Share this post


Link to post
Share on other sites

Hello,

I just PMed you. Thank you for your support.

Best regards

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0