Ignore:
Timestamp:
12/29/12 10:03:12 (11 years ago)
Author:
István Váradi <ivaradi@…>
Branch:
default
Phase:
public
Message:

Moved the storage of the error code to where it belongs

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/xplcommon/posix/ServerSocket.h

    r6 r14  
    7575     * @param reuseaddr if set to true, the SO_REUSEADDR socket option
    7676     * will be set.
     77     *
     78     * @return if the binding has succeeded. If it is false, the error
     79     * code will be set accordingly.
    7780     */
    78     int bind(const struct sockaddr* addr, size_t addrlen,
    79              bool reuseaddr = true);
     81    bool bind(const struct sockaddr* addr, size_t addrlen,
     82              bool reuseaddr = true);
    8083
    8184    /**
    8285     * Start listening on the socket.
     86     *
     87     * @return if the call has succeeded. If it is false, the error
     88     * code will be set accordingly.
    8389     */
    84     int listen(int backlog = 5);
     90    bool listen(int backlog = 5);
     91
     92    /**
     93     * Accept a socket.
     94     *
     95     * @return the accepted socket. If may be -1, if the socket is
     96     * non-blocking, and no connection is available yet, or if another
     97     * error occured, in which case the error code will be set properly.
     98     */
     99    int accept(struct sockaddr* addr, size_t* addrlen);
    85100
    86101    friend class Acceptor;
Note: See TracChangeset for help on using the changeset viewer.