> I don't know much about networking.  You could catch the error, or if you
> want it more explicitly do something like.  
>
> (condition-case nil
>         (url-retrieve-synchronously "http://www.gnu.org";)
>         (error nil))
>
> (condition-case nil
>         (url-retrieve-synchronously 
> "www.nonexisting.domain.somewhere.out.there123")
>         (error nil))
>
> You'd probably need to clean up the buffer as well.
>
> http://www.gnu.org/software/emacs/manual/html_node/elisp/Handling-Errors.html

All of those would hang Emacs. It makes more sense to asynchronously ask
something like ping to do it and check back on that. I'm sure that there
is a canonical way for Emacs to check if it has an Internet connection,
and I even remember reading a conversation about this issue on
emacs-devel... who knows how long ago that was.

-- 
   "Cut your own wood and it will warm you twice"

_______________________________________________
Emms-help mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/emms-help

Reply via email to