tidy up output a bit. No longer show "accepted connection" inside Telnet session.

git-svn-id: svn://svn.berlios.de/openocd/trunk@497 b42882b7-edfa-0310-969c-e2dbd0fdcd60
This commit is contained in:
oharboe 2008-03-11 21:17:46 +00:00
parent 1812a3535c
commit d1fe9bacbb
1 changed files with 3 additions and 2 deletions

View File

@ -62,14 +62,15 @@ int add_connection(service_t *service, command_context_t *cmd_ctx)
address_size = sizeof(c->sin); address_size = sizeof(c->sin);
c->fd = accept(service->fd, (struct sockaddr *)&service->sin, &address_size); c->fd = accept(service->fd, (struct sockaddr *)&service->sin, &address_size);
INFO("accepting '%s' connection from %i", service->name, c->sin.sin_port);
if ((retval = service->new_connection(c)) == ERROR_OK) if ((retval = service->new_connection(c)) == ERROR_OK)
{ {
INFO("accepted '%s' connection from %i", service->name, c->sin.sin_port);
} }
else else
{ {
close_socket(c->fd); close_socket(c->fd);
INFO("attempted '%s' connection rejected", service->name); ERROR("attempted '%s' connection rejected", service->name);
free(c); free(c);
return retval; return retval;
} }