$OpenBSD: patch-x11_serverping_cpp,v 1.3 2018/04/08 13:36:10 jasper Exp $
Index: x11/serverping.cpp
--- x11/serverping.cpp.orig
+++ x11/serverping.cpp
@@ -25,8 +25,11 @@
 // code and should be reasonably easy to compile on Windows.
 
 
-#include <iostream.h>
-#include <strstream.h>
+#include <iostream>
+#include <strstream>
+
+using namespace std;
+
 #include "utils.h"
 #include "streams.h"
 #include "xetp_basic.h"
@@ -170,7 +173,7 @@ ServerPing::ServerPing(int argc,char** argv) {
   client.sin_family = AF_INET;
   client.sin_addr.s_addr = htonl(INADDR_ANY);
   client.sin_port = htons((u_short)clientPort);
-  if (bind(udpSock,(CMN_SOCKADDR *)&client,sizeof(client)) < 0) {
+  if (::bind(udpSock,(CMN_SOCKADDR *)&client,sizeof(client)) < 0) {
     ostrstream str;
     str << "Could not bind local UDP port " << clientPort << ends;
     error(str.str());
@@ -355,6 +358,7 @@ void ServerPing::print_results_and_exit() {
 
 
 
+int
 main(int argc,char** argv) {
   ServerPing ping(argc,argv);
   ping.go();
