The WiFi.h and WiFiServer.h libraries do not work with the Yun - they are designed for a typical Arduino with a WiFi shield. Networking on the Yun is completely different.
On the Yun, use the BridgeServer and BridgeClient classes that are part of the Bridge Library, or the HttpClient class that is also part of the Bridge library. Or implement your network services on the Linux side (more difficult, but much more powerful) and use the Process class in your sketch to pass data between thvsketch and the Linux side.)