≡

wincent.dev

  • Products
  • Blog
  • Wiki
  • Issues
You are viewing an historical archive of past issues. Please report new issues to the appropriate project issue tracker on GitHub.
Home » Issues » Bug #131

Bug #131: Lengthy hangs without an internet connection

Kind bug
Product Synergy
When Created 2005-03-08T19:35:35Z, updated 2005-03-13T02:24:35Z
Status closed
Reporter Eerk
Tags no tags

Description

This is a bug I have hoped to be resolved for several versions now, but it seems not to happen. Therefore a try at a report. Being forced to a slow and expensive dial-up internet connection in this part of the Netherlands, I try to keep internet connections as short as possible. Just to get some album covers I switched on the option to show them in the floater and jumped through songs for half an hour to get their album art in (seems my musical taste is not main stream, for just a few albums made it in ;-) All was fine: Synergy was responsive and keyboard requests for next and previous songs worked as advertised (Sidestep: as reported by someone else, the art is not displayed in the floater without switching back and forth the currently playing song). But then I disconnected my internet connection and switched off any setting that in my opinion could have anything to do with that connection, including _not_ displaying album covers in the floater anymore. And that's when the 'hanging' starts. Any change in songs takes up to a minute to be reflected. Just two examples: changes to the button set are reflected in this menu only after minutes and finally clicking 'Stop Synergy' took the same amount of time. All this time, hovering the mouse above the Synergy menu shows a spinning beach ball 9 out of 10 times. This bug has been around for as long as I remember (I started using Synergy around version 1.0). Because most of my computer time is spent off-line, this bug has forced me (unfortunately) to switch off Synergy once again. That's not what I want, the functionality is great, so if you can guide me to some tests that could clarify this bug, I am happy to work with you in this.

With kind regards,

Eerk Hofmeester.

Comments

  1. Eerk 2005-03-08T19:39:01Z

    An additional note that is possibly related: starting my computer definitely takes much (a minute or so) longer when Synergy is switched on at log-in. I tried restarting after switching off Synergy at log-in and the startup process was as expected.

  2. Greg Hurrell 2005-03-08T21:10:40Z

    What's the effect of the setting (in the Advanced tab of the Synergy preferences), "Initiate connections to the Internet automatically when required (may cause Synergy to initiate a dial-up connection)"?

    Is it on, or off? What happens when you switch it?

    I am not looking at the source code right now, but from memory Synergy uses the SCNetworkCheckReachabilityByName API (or a similar one in the SCNetwork group) to check whether or not a host is reachable. The docs don't say anything about possible delays, but if the call to that API is causing the delay, I might have to move it into a separate thread.

    Marking as ASSIGNED.

  3. Eerk 2005-03-08T23:59:47Z

    Hello Wincent,

    Thanks for the quick reply. The option "Initiate connections etc." is off. It is one of the options I mentioned I have switched off after quiting the album download (and therefore the internet connection).

    Give me a minute...

    I just did an interesting test: switching the internet connection off (with album artwork visible in the floater) is no problem untill I switch to a song that has _iTunes_ artwork connected to it. Switching back and forth between songs that have no or Synergy artwork connected, is no problem. Lag time is about 30 to 40 seconds before any response of Synergy comes back. When I switch the internet connection back on (because I wanted to send in this form) the response times are back to normal. Seems looking up (and finding) iTunes artwork causes this.

    Hope this helps,

    Eerk Hofmeester.

  4. Eerk 2005-03-09T00:10:46Z

    Hello Wincent,

    Yet another comment after testing further: this won't help I'm afraid, but the lag time also occurs with the album art switched off. Also my previous suggestion seems to be only half true. When switching to songs that have no iTunes artwork the lag can also occur. Only advantage is, is that my collection of Synergy artwork is growing steadily with all this on-line testing ;-)

    Kind regards, Eerk Hofmeester.

  5. Eerk 2005-03-09T01:06:43Z

    Just timed the lag time: it's exactly 60 seconds. Regards, Eerk.

  6. Greg Hurrell 2005-03-12T06:18:55Z

    Ok. I believe I've fixed this. I am sending you a test build to your email address. Please let me know if it cures the problems.

    There are two reasons why Synergy would connect to the net: (1) automatic version checking, and (2) Amazon searching. In the former case, Synergy first needs to know if the update host is reachable, and in the latter, whether xml.amazon.com is reachable.

    I think the problem lay in the calls to the SCNetworkCheckReachabilityByName API. My interpretation of the docs was that if there was no net connection then the function would just return immediately and say "not reachable". But the fact that you see an exactly 60 second delay implies that it's getting up to some other mischief. Perhaps it's doing DNS lookups that are timing out or something.

    In any case, I've done a bit of refactoring and moved the reachability checks for both situations (1) and (2) into separate threads. This means there should be no more delays.

    Can you please test out the build? I will email it to you in a minute or two, after I've finished posting this comment. I'd like to know if it fixes the delays, if the "Initiate connections to the Internet automatically when required" checkbox works properly, and if your album cover downloads etc continue to work. I've done as much testing as I can here, and it seems to all work. But seeing as I never had the delays (I've got an always-on ADSL connection) I will only know for sure that it's fixed if you can confirm it for me.

  7. Eerk 2005-03-12T09:18:06Z

    Hello Wincent,

    Just received the build per e-mail. It's a little late now, but I will test it first thing when I startup my Mac again somewhere this weekend. Thanks for the quick work on this!

    Regards, Eerk.

  8. Eerk 2005-03-13T00:07:42Z

    Hello Wincent,

    SUCCES! I installed 'my' 1.7.1 version and couldn't get it to lag, with or without a connection. Some additional artwork came in, so the connection (when available) is still used correctly. Just to be sure, I re-installed the original 1.7.1 version and sure enough, within seconds after going to a new song, the spinning beach ball was back. Installed the fixed 1.7.1 and all is well again. It seems your trick did it!

    I think you can safely post 1.7.2 on the web.

    Working with this version so intensely I came up with another wish for the list. I will post it in a separate thread.

    Cheers and thanks a lot for your quick fix!

    Eerk Hofmeester

  9. Greg Hurrell 2005-03-13T02:19:33Z

    Excellent news. Glad to hear the fix works. Marked as FIXED.

  10. Greg Hurrell 2005-03-13T02:24:35Z

    Marking as CLOSED.

    Note to everyone else: If you're suffering from this bug and want to use the build that fixes it, you can pull it down.

    MD5 checksum: e632d092a5dbaec849d98c5f877a525a

    This is not an official release. It's identical in every way to the 1.7.1 release, apart from the fix. The fix will be officially released when 1.8 comes out (later this month, if my current schedule works out).

Add a comment

Comments are now closed for this issue.

  • contact
  • legal

Menu

  • Blog
  • Wiki
  • Issues
  • Snippets