rejetto forum

Software => HFS ~ HTTP File Server => Topic started by: MarkV on June 03, 2006, 03:44:25 PM

Title: Small bug with updatechecker
Post by: MarkV on June 03, 2006, 03:44:25 PM
If for some reason a file with the name hfs.updateinfo.txt exists in HFS program folder, the update check does no longer work (Communication error).

If the local file's format is correct, it's even possible to show fake info!

(http://img187.imageshack.us/img187/4909/hfsforged5ji.jpg) (http://imageshack.us)

(http://img310.imageshack.us/img310/3107/hfsforged25oe.jpg) (http://imageshack.us)

8O 8O 8O

MarkV
Title: Small bug with updatechecker
Post by: rejetto on June 03, 2006, 04:11:56 PM
that is not a bug, it is a feature :)

anyone reading the sources can see this
Code: [Select]
 URL = 'http://www.rejetto.com/hfs/hfs.updateinfo.txt';
  ON_DISK = 'hfs.updateinfo.txt';

...

// this let the developer to be not connected when testing the parsing
if fileExists(ON_DISK) then s:=loadFile(ON_DISK)
else s:=httpGet(URL);


it is not documented because only developers need it
Title: Small bug with updatechecker
Post by: MarkV on June 03, 2006, 04:24:38 PM
But if the file accidently exists on disk, the updatechecker does not work and nobody knows why... well, except the developers.

MarkV
Title: Small bug with updatechecker
Post by: rejetto on June 03, 2006, 04:43:11 PM
suggestions?
Title: Small bug with updatechecker
Post by: rejetto on June 03, 2006, 04:44:12 PM
suggestion #1
limit this behaviour to betas only
Title: Small bug with updatechecker
Post by: MarkV on June 03, 2006, 10:56:07 PM
It would be enough to mention in the update dialog if the info was parsed locally and not downloaded off the internet...

Or insert a warning before the update dialog:
Code: [Select]
Attention! Update info has been read from local file. To resume normal operation of the updater, delete the file hfs.updateinfo.txt from the HFS program folder.
No need to disable, just inform...

MarkV
Title: Small bug with updatechecker
Post by: rejetto on June 06, 2006, 06:52:16 PM
good point