diff options
-rw-r--r-- | src/base/vnc/vncserver.cc | 7 | ||||
-rw-r--r-- | src/dev/serial/terminal.cc | 7 |
2 files changed, 4 insertions, 10 deletions
diff --git a/src/base/vnc/vncserver.cc b/src/base/vnc/vncserver.cc index 97515ac16..a37f1dd5e 100644 --- a/src/base/vnc/vncserver.cc +++ b/src/base/vnc/vncserver.cc @@ -174,11 +174,8 @@ VncServer::listen(int port) port++; } - int p1, p2; - p2 = name().rfind('.') - 1; - p1 = name().rfind('.', p2); - ccprintf(cerr, "Listening for %s connection on port %d\n", - name().substr(p1 + 1, p2 - p1), port); + ccprintf(cerr, "%s: Listening for connections on port %d\n", + name(), port); listenEvent = new ListenEvent(this, listener.getfd(), POLLIN); pollQueue.schedule(listenEvent); diff --git a/src/dev/serial/terminal.cc b/src/dev/serial/terminal.cc index 5e8e52e95..bc8c14c53 100644 --- a/src/dev/serial/terminal.cc +++ b/src/dev/serial/terminal.cc @@ -153,11 +153,8 @@ Terminal::listen(int port) port++; } - int p1, p2; - p2 = name().rfind('.') - 1; - p1 = name().rfind('.', p2); - ccprintf(cerr, "Listening for %s connection on port %d\n", - name().substr(p1+1,p2-p1), port); + ccprintf(cerr, "%s: Listening for connections on port %d\n", + name(), port); listenEvent = new ListenEvent(this, listener.getfd(), POLLIN); pollQueue.schedule(listenEvent); |