Skip to content
Snippets Groups Projects
Commit 7b8b1e3d authored by Jesper Zedlitz's avatar Jesper Zedlitz
Browse files

don't exit on pressed key

parent e5d8b173
No related branches found
No related tags found
No related merge requests found
Pipeline #240 passed
package de.landsh.opendata.dataproxy; package de.landsh.opendata.dataproxy;
import fi.iki.elonen.NanoHTTPD; import fi.iki.elonen.NanoHTTPD;
import fi.iki.elonen.util.ServerRunner;
import java.io.IOException;
public class App extends NanoHTTPD { public class App extends NanoHTTPD {
public static int port = 8080; public static int port = 8080;
...@@ -14,7 +15,7 @@ public class App extends NanoHTTPD { ...@@ -14,7 +15,7 @@ public class App extends NanoHTTPD {
System.out.println("\nRunning! Point your browser to http://localhost:" + port + "/ \n"); System.out.println("\nRunning! Point your browser to http://localhost:" + port + "/ \n");
} }
public static void main(String[] args) { public static void main(String[] args) throws IOException {
if (args.length > 0) { if (args.length > 0) {
try { try {
...@@ -25,7 +26,7 @@ public class App extends NanoHTTPD { ...@@ -25,7 +26,7 @@ public class App extends NanoHTTPD {
} }
} }
ServerRunner.run(App.class); new App().start(5000, false);
} }
@Override @Override
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment