rejetto forum

Small bug with updatechecker

MarkV · 7 · 3604

0 Members and 1 Guest are viewing this topic.

Offline MarkV

  • Tireless poster
  • ****
    • Posts: 764
    • View Profile
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!





8O 8O 8O

MarkV
http://worldipv6launch.org - The world is different now.


Offline rejetto

  • Administrator
  • Tireless poster
  • *****
    • Posts: 13523
    • View Profile
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


Offline MarkV

  • Tireless poster
  • ****
    • Posts: 764
    • View Profile
But if the file accidently exists on disk, the updatechecker does not work and nobody knows why... well, except the developers.

MarkV
http://worldipv6launch.org - The world is different now.


Offline rejetto

  • Administrator
  • Tireless poster
  • *****
    • Posts: 13523
    • View Profile

Offline rejetto

  • Administrator
  • Tireless poster
  • *****
    • Posts: 13523
    • View Profile
suggestion #1
limit this behaviour to betas only


Offline MarkV

  • Tireless poster
  • ****
    • Posts: 764
    • View Profile
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
http://worldipv6launch.org - The world is different now.


Offline rejetto

  • Administrator
  • Tireless poster
  • *****
    • Posts: 13523
    • View Profile