Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset 2d68c72 in mainline


Ignore:
Timestamp:
2010-01-04T17:32:25Z (12 years ago)
Author:
Lukas Mejdrech <lukas@…>
Branches:
lfn, master
Children:
9d28b9c
Parents:
7586c85
Message:

+ echo prints socket identifier if verbose

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/net/app/echo/echo.c

    r7586c85 r2d68c72  
    282282        }
    283283
    284         socket_id = listening_id;
    285 
    286284        if( ERROR_OCCURRED( bind( listening_id, address, addrlen ))){
    287285                socket_print_error( stderr, ERROR_CODE, "Socket bind: ", "\n" );
     
    289287        }
    290288
    291         if( verbose ) printf( "Listenning at %d\n", port );
     289        if( verbose ) printf( "Socket %d listenning at %d\n", listening_id, port );
     290
     291        socket_id = listening_id;
    292292
    293293        while( count ){
     
    325325                                                }else{
    326326                                                        data[ length ] = '\0';
    327                                                         printf( "Received %d bytes from %s:%d\n%s\n", length, address_string, port, data );
     327                                                        printf( "Socket %d received %d bytes from %s:%d\n%s\n", socket_id, length, address_string, port, data );
    328328                                                }
    329329                                        }
Note: See TracChangeset for help on using the changeset viewer.