Encountered a very strange problem with C# HttpListener. After trying to add a new prefix to it, it started treating every URL as invalid - including localhost, which, looking at other questions I've looked through, works every time.
Code I'm using is nothing complicated, but, still, here it is
using HttpListener listener = new HttpListener();
listener.Prefixes.Add("http://localhost/");
listener.Start();
Specifically, error I'm getting is the following:
System.Net.HttpListenerException (1214): The format of the specified network name is not valid