vibe.d Error only with Firefox

Steven Schveighoffer schveiguy at yahoo.com
Fri Jan 5 16:47:53 UTC 2018


On 1/5/18 11:30 AM, Martin Tschierschke wrote:
> Hello,
> when starting my vibe.d service I get the message of failed address 
> binding:
> Failed to listen on 127.0.0.1:8030
> Failed to listen on 10.0.0.1:8030
> object.Exception at ../../.dub/packages/vibe-d-0.8.2-rc.2/vibe-d/http/vibe/http/server.d(2035): 
> Failed to listen for incoming HTTP connections on any of the supplied 
> interfaces.

It's attempting to listen on localhost:8030, and 10.0.0.1:8030, but 
can't bind to either address. Then it looks like you get an exception. 
Does it actually continue running?

> 
> This has been mentioned here:
> http://forum.rejectedsoftware.com/groups/rejectedsoftware.vibed/thread/3480/ 

This is a different problem, where it attempts to listen on INADDR_ANY 
for both IPv6 and IPv4, but binding to IPv6 automatically binds to IPv4, 
so the second listen fails. One succeeded, so notice you don't get an 
exception.

> The strange thing is now, that when using Chromium http://10.0.0.1:8030 
> works!

Hm.. there are 2 possibilities here:
1. You have another statement somewhere in the same program which 
listens on that port/address combo (or INADDR_ANY on that port).
2. There's another program that has already bound to that address.

Use netstat to see if any program is listening, perhaps you have a stale 
version of your server running?

> But with Firefox http://10.0.0.1:8030
> 
> gives the long Error:
> 400 - Bad Request
> 
> Bad Request
> 
> Internal error information:
> object.Exception at ../../.dub/packages/vibe-d-0.8.2-rc.2/vibe-d/stream/vibe/stream/operations.d(363): 
> Reached maximum number of bytes while searching for end marker.
> ----------------
> ....
> truncated
> .....
> ../../.dub/packages/vibe-d-0.8.2-rc.2/vibe-d/core/vibe/core/core.d:1269 
> void vibe.core.core.CoreTask.run() [0x94574a]
> ??:? void core.thread.Fiber.run() [0xa3c7ff]
> ??:? fiber_entryPoint [0xa3c562]
> ??:? [0xffffffff]

This looks like a real error that isn't related to the bindings (as long 
as it's not some weird stale server). I'd suggest trying to create a 
minimal example and post it to vibe.d's issue tracker.

> 
> On the other side, when using http://localhost:8030/ or any other domain 
> mapped to to 10.0.0.1 (in /etc/hosts) even Firefox works.

I think you need to post a working example in order for anyone to diagnose.

-Steve


More information about the Digitalmars-d mailing list