summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Xtrans.c2
-rw-r--r--Xtrans.h2
-rw-r--r--Xtransint.h2
-rw-r--r--Xtranslcl.c3
-rw-r--r--Xtranssock.c5
-rw-r--r--doc/xtrans.xml8
6 files changed, 12 insertions, 10 deletions
diff --git a/Xtrans.c b/Xtrans.c
index 79b3b31..86ccdd0 100644
--- a/Xtrans.c
+++ b/Xtrans.c
@@ -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);
diff --git a/Xtrans.h b/Xtrans.h
index b93e587..7706621 100644
--- a/Xtrans.h
+++ b/Xtrans.h
@@ -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>