diff options
author | Alan Coopersmith <alan.coopersmith@oracle.com> | 2014-08-23 10:17:57 -0700 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@oracle.com> | 2014-08-23 12:47:32 -0700 |
commit | 63b65a20706def951dd25e531949b7bc556419eb (patch) | |
tree | af20aa218a5a96f86366767fdbe12aef8c24419e | |
parent | fd90a4e00321b22c96565cfa354b8b0efa376979 (diff) |
Add const qualifiers to TRANS(CreateListener) port args
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r-- | Xtrans.c | 2 | ||||
-rw-r--r-- | Xtrans.h | 2 | ||||
-rw-r--r-- | Xtransint.h | 2 | ||||
-rw-r--r-- | Xtranslcl.c | 3 | ||||
-rw-r--r-- | Xtranssock.c | 5 | ||||
-rw-r--r-- | doc/xtrans.xml | 8 |
6 files changed, 12 insertions, 10 deletions
@@ -743,7 +743,7 @@ TRANS(SetOption) (XtransConnInfo ciptr, int option, int arg) #ifdef TRANS_SERVER int -TRANS(CreateListener) (XtransConnInfo ciptr, char *port, unsigned int flags) +TRANS(CreateListener) (XtransConnInfo ciptr, const char *port, unsigned int flags) { return ciptr->transptr->CreateListener (ciptr, port, flags); @@ -299,7 +299,7 @@ int TRANS(SetOption)( int TRANS(CreateListener)( XtransConnInfo, /* ciptr */ - char *, /* port */ + const char *, /* port */ unsigned int /* flags */ ); diff --git a/Xtransint.h b/Xtransint.h index 5f7718e..285cf5b 100644 --- a/Xtransint.h +++ b/Xtransint.h @@ -233,7 +233,7 @@ typedef struct _Xtransport { int (*CreateListener)( XtransConnInfo, /* connection */ - char *, /* port */ + const char *, /* port */ unsigned int /* flags */ ); diff --git a/Xtranslcl.c b/Xtranslcl.c index 78572b3..dec8124 100644 --- a/Xtranslcl.c +++ b/Xtranslcl.c @@ -2151,7 +2151,8 @@ TRANS(LocalSetOption)(XtransConnInfo ciptr, int option, int arg) #ifdef TRANS_SERVER static int -TRANS(LocalCreateListener)(XtransConnInfo ciptr, char *port, unsigned int flags _X_UNUSED) +TRANS(LocalCreateListener)(XtransConnInfo ciptr, const char *port, + unsigned int flags _X_UNUSED) { prmsg(2,"LocalCreateListener(%p->%d,%s)\n",ciptr,ciptr->fd,port); diff --git a/Xtranssock.c b/Xtranssock.c index 1b1dd7e..87efd1b 100644 --- a/Xtranssock.c +++ b/Xtranssock.c @@ -947,7 +947,8 @@ TRANS(SocketCreateListener) (XtransConnInfo ciptr, #ifdef TCPCONN static int -TRANS(SocketINETCreateListener) (XtransConnInfo ciptr, char *port, unsigned int flags) +TRANS(SocketINETCreateListener) (XtransConnInfo ciptr, const char *port, + unsigned int flags) { #if defined(IPv6) && defined(AF_INET6) @@ -1075,7 +1076,7 @@ TRANS(SocketINETCreateListener) (XtransConnInfo ciptr, char *port, unsigned int #ifdef UNIXCONN static int -TRANS(SocketUNIXCreateListener) (XtransConnInfo ciptr, char *port, +TRANS(SocketUNIXCreateListener) (XtransConnInfo ciptr, const char *port, unsigned int flags) { diff --git a/doc/xtrans.xml b/doc/xtrans.xml index 5960dfa..2e16e79 100644 --- a/doc/xtrans.xml +++ b/doc/xtrans.xml @@ -226,8 +226,8 @@ typedef struct _Xtransport { int (*CreateListener)( XtransConnInfo, /* connection */ - char *, /* port */ - int /* flags */ + const char *, /* port */ + int /* flags */ ); int (*ResetListener)( @@ -480,7 +480,7 @@ Based on current usage, the complimentary function <funcprototype> <funcdef>int <function>TRANS(CreateListener)</function></funcdef> <paramdef>XtransConnInfo <parameter>connection</parameter></paramdef> - <paramdef>char *<parameter>port</parameter></paramdef> + <paramdef>const char *<parameter>port</parameter></paramdef> <paramdef>int <parameter>flags</parameter></paramdef> </funcprototype> </funcsynopsis> @@ -935,7 +935,7 @@ different transport type is added, or a transport dependent option is defined. <funcprototype> <funcdef>int <function>CreateListener</function></funcdef> <paramdef>struct _Xtransport *<parameter>thistrans</parameter></paramdef> - <paramdef>char <parameter>*port</parameter></paramdef> + <paramdef>const char <parameter>*port</parameter></paramdef> <paramdef>int <parameter>flags</parameter></paramdef> </funcprototype> </funcsynopsis> |