Changeset 257feec in mainline for uspace/lib


Ignore:
Timestamp:
2013-06-27T12:48:32Z (12 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
9f391e9
Parents:
679ee84
Message:

cstyle (no change in functionality)

Location:
uspace/lib/c/include/net
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/include/net/in.h

    r679ee84 r257feec  
    4545#define INET_ADDRSTRLEN  (4 * 3 + 3 + 1)
    4646
    47 #define INADDR_ANY 0
     47#define INADDR_ANY  0
    4848
    4949/** INET address. */
  • uspace/lib/c/include/net/in6.h

    r679ee84 r257feec  
    4343
    4444/** INET6 string address maximum length. */
    45 #define INET6_ADDRSTRLEN        (8 * 4 + 7 + 1)
    46 
    47 /** Type definition of the INET6 address.
    48  * @see in6_addr
    49  */
    50 typedef struct in6_addr in6_addr_t;
    51 
    52 /** Type definition of the INET6 socket address.
    53  * @see sockaddr_in6
    54  */
    55 typedef struct sockaddr_in6     sockaddr_in6_t;
     45#define INET6_ADDRSTRLEN  (8 * 4 + 7 + 1)
    5646
    5747/** INET6 address. */
    58 struct in6_addr {
     48typedef struct in6_addr {
    5949        /** 16 byte IPv6 address. */
    60         unsigned char s6_addr[16];
    61 };
     50        uint8_t s6_addr[16];
     51} in6_addr_t;
    6252
    6353/** INET6 socket address.
    6454 * @see sockaddr
    6555 */
    66 struct sockaddr_in6 {
     56typedef struct sockaddr_in6 {
    6757        /** Address family. Should be AF_INET6. */
    6858        uint16_t sin6_family;
     
    7565        /** Scope identifier. */
    7666        uint32_t sin6_scope_id;
    77 };
     67} sockaddr_in6_t;
    7868
    7969#endif
  • uspace/lib/c/include/net/inet.h

    r679ee84 r257feec  
    4141#include <byteorder.h>
    4242
    43 /** Type definition of the socket address.
    44  * @see sockaddr
    45  */
    46 typedef struct sockaddr         sockaddr_t;
    47 
    4843/** Type definition of the address information.
    4944 * @see addrinfo
    5045 */
    51 typedef struct addrinfo         addrinfo_t;
     46typedef struct addrinfo addrinfo_t;
    5247
    5348/** Socket address. */
    54 struct sockaddr {
     49typedef struct sockaddr {
    5550        /** Address family. @see socket.h */
    5651        uint16_t sa_family;
    5752        /** 14 byte protocol address. */
    5853        uint8_t sa_data[14];
    59 };
     54} sockaddr_t;
    6055
    6156extern int inet_ntop(uint16_t, const uint8_t *, char *, size_t);
  • uspace/lib/c/include/net/socket_codes.h

    r679ee84 r257feec  
    4646enum {
    4747        AF_NONE = 0,
    48         AF_INET,        /* IPv4 address */
    49         AF_INET6        /* IPv6 address */
     48        AF_INET,  /* IPv4 address */
     49        AF_INET6  /* IPv6 address */
    5050};
    5151
     
    5353
    5454/** @name Protocol families definitions
    55  *  Same as address families.
     55 * Same as address families.
    5656 */
    5757/*@{*/
    5858
    59 #define PF_INET         AF_INET
    60 #define PF_INET6        AF_INET6
     59#define PF_INET   AF_INET
     60#define PF_INET6  AF_INET6
    6161
    6262/*@}*/
Note: See TracChangeset for help on using the changeset viewer.