[Opensrf-commits] r1236 - in trunk: include/opensrf src/libopensrf
svn at svn.open-ils.org
svn at svn.open-ils.org
Thu Jan 31 14:37:25 EST 2008
Author: miker
Date: 2008-01-31 14:09:46 -0500 (Thu, 31 Jan 2008)
New Revision: 1236
Modified:
trunk/include/opensrf/socket_bundle.h
trunk/src/libopensrf/socket_bundle.c
Log:
Patch from Scott McKellar to fix up some const correctness issues.
Modified: trunk/include/opensrf/socket_bundle.h
===================================================================
--- trunk/include/opensrf/socket_bundle.h 2008-01-31 19:07:30 UTC (rev 1235)
+++ trunk/include/opensrf/socket_bundle.h 2008-01-31 19:09:46 UTC (rev 1236)
@@ -69,7 +69,7 @@
socket_type is one of INET or UNIX */
int socket_open_tcp_server(socket_manager*, int port, const char* listen_ip );
-int socket_open_unix_server(socket_manager* mgr, char* path);
+int socket_open_unix_server(socket_manager* mgr, const char* path);
int socket_open_udp_server( socket_manager* mgr, int port, const char* listen_ip );
@@ -81,7 +81,7 @@
returns 0 on success. -1 on failure. */
int socket_open_unix_client(socket_manager*, const char* sock_path);
-int socket_open_udp_client( socket_manager* mgr, int port, char* dest_addr);
+int socket_open_udp_client( socket_manager* mgr, int port, const char* dest_addr);
/* sends the given data to the given socket. returns 0 on success, -1 otherwise */
int socket_send(int sock_fd, const char* data);
Modified: trunk/src/libopensrf/socket_bundle.c
===================================================================
--- trunk/src/libopensrf/socket_bundle.c 2008-01-31 19:07:30 UTC (rev 1235)
+++ trunk/src/libopensrf/socket_bundle.c 2008-01-31 19:09:46 UTC (rev 1236)
@@ -129,7 +129,7 @@
return sock_fd;
}
-int socket_open_unix_server(socket_manager* mgr, char* path) {
+int socket_open_unix_server(socket_manager* mgr, const char* path) {
if(mgr == NULL || path == NULL) return -1;
osrfLogDebug( OSRF_LOG_MARK, "opening unix socket at %s", path);
@@ -291,7 +291,7 @@
int socket_open_udp_client(
- socket_manager* mgr, int port, char* dest_addr) {
+ socket_manager* mgr, int port, const char* dest_addr) {
int sockfd;
struct sockaddr_in client_addr, server_addr;
More information about the opensrf-commits
mailing list