You are here

Patch for PAI

3 posts / 0 new
Last post
Gord Caswell
Gord Caswell's picture
Offline
Last seen: 2 days 4 hours ago
DeveloperModerator
Joined: 2008-07-24 18:46
Patch for PAI

In response to the issue raised here, regarding the installer deleting the App\AppName directory when downloading a file is unsuccessful, I decided to see if I could patch it.

I think I might have managed to get it to work. Please test extensively.

I have tested with a few different scenarios, and my computer hasn't blown up yet, so that's a good sign.

With that said, I'm not sure if this has caused any other issues.

John, in particular, since this is your app, please verify if this does indeed work without causing further harm.

Hope that helps with the problem!

The modified nsi can be found here: http://pastebin.com/KBRUceRJ

Chris Morgan
Chris Morgan's picture
Offline
Last seen: 9 years 5 months ago
Joined: 2007-04-15 21:08
Wrong place

You've modified Other\Source\InstallerWizard.nsi (reordering one chunk to another place), which is purely the installer wizard; what you've changed will actually have no effect. What needs to be done is to make the actual installer (i.e. App\installer\PortableApps.comInstaller.nsi) download the file before removing files from the previous version.

Now I've finally got round to looking at it briefly, and I can't see anything immediately wrong with splitting the !ifdef DownloadURL section into "downloading" (961-1023 and 1121-1133) and "extracting" (1024-1120) portions, and shifting the "downloading" portion to immediately after line 817 (i.e. just before getting to CustomCodeOptionalCleanup and CustomCodePreInstall, this also secures them a little more). John, does this seem sound? The only "hazard" I can think of with this is if TEMP is on the same drive as the target installation directory and doesn't have enough space for both the old installation and the installer... but we've said before that we don't cater for this sort of situation.

I am a Christian and a developer and moderator here.

“A soft answer turns away wrath, but a harsh word stirs up anger.” – Proverbs 15:1

depp.jones
Offline
Last seen: 1 day 6 hours ago
DeveloperTranslator
Joined: 2010-06-05 17:19
Thanks for picking that up!

Thanks for picking that up! Even after Chris pointed to the relevant bits it still is an awful lot of puzzling instructions for me. I am studying the code for now and think I understand the diferent sections but it still seems a little bit too complex for me to make any changes that might actually work. Wink

Log in or register to post comments