/[monit]/monit/net.h
ViewVC logotype

Diff of /monit/net.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.17 by hauk, Mon Aug 4 07:52:12 2003 UTC revision 1.18 by hauk, Wed Sep 3 23:28:38 2003 UTC
# Line 53  Line 53 
53   * @param protocol The socket protocol to use   * @param protocol The socket protocol to use
54   * @return TRUE if the connect succeeded otherwise FALSE.   * @return TRUE if the connect succeeded otherwise FALSE.
55   */   */
56  int check_connect(char *hostname, int port, int protocol);  int check_connect(const char *hostname, int port, int protocol);
57    
58    
59  /**  /**
# Line 61  int check_connect(char *hostname, int po Line 61  int check_connect(char *hostname, int po
61   * @param hostname The host to check   * @param hostname The host to check
62   * @return TRUE if hostname resolves, otherwise FALSE   * @return TRUE if hostname resolves, otherwise FALSE
63   */   */
64  int check_host(char *hostname);  int check_host(const char *hostname);
65    
66    
67  /**  /**
# Line 96  int check_udp_socket(int socket); Line 96  int check_udp_socket(int socket);
96   * @param timeout If not connected within timeout seconds abort and return -1   * @param timeout If not connected within timeout seconds abort and return -1
97   * @return The socket or -1 if an error occured.   * @return The socket or -1 if an error occured.
98   */   */
99  int create_socket(char *hostname, int port, int protocol, int timeout);  int create_socket(const char *hostname, int port, int protocol, int timeout);
100    
101    
102  /**  /**
# Line 114  int create_generic_socket(Port_T p); Line 114  int create_generic_socket(Port_T p);
114   * @param timeout If not connected within timeout seconds abort and return -1   * @param timeout If not connected within timeout seconds abort and return -1
115   * @return The socket or -1 if an error occured.   * @return The socket or -1 if an error occured.
116   */   */
117  int create_unix_socket(char *pathname, int timeout);  int create_unix_socket(const char *pathname, int timeout);
118    
119    
120  /**  /**
# Line 129  int create_unix_socket(char *pathname, i Line 129  int create_unix_socket(char *pathname, i
129   * @param bindAddr the local address the server will bind to   * @param bindAddr the local address the server will bind to
130   * @return The socket ready for accept, or -1 if an error occured.   * @return The socket ready for accept, or -1 if an error occured.
131   */   */
132  int create_server_socket(int port, int backlog, char *bindAddr);  int create_server_socket(int port, int backlog, const char *bindAddr);
133    
134    
135  /**  /**
# Line 184  int can_write(int socket, int timeout); Line 184  int can_write(int socket, int timeout);
184   * @param size Number of bytes to send   * @param size Number of bytes to send
185   * @return The number of bytes sent or -1 if an error occured.   * @return The number of bytes sent or -1 if an error occured.
186   */   */
187  int sock_write(int socket, void *buffer, int size);  int sock_write(int socket, const void *buffer, int size);
188    
189    
190  /**  /**

Legend:
Removed from v.1.17  
changed lines
  Added in v.1.18

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26