removed const-ness from clean_ttyname

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@1761 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Assar Westerlund
1997-05-25 01:14:33 +00:00
parent 1ebf8e5148
commit 04a4f72a3d
2 changed files with 9 additions and 9 deletions

View File

@@ -44,10 +44,10 @@ RCSID("$Id$");
* Clean the tty name. Return a pointer to the cleaned version. * Clean the tty name. Return a pointer to the cleaned version.
*/ */
const char * char *
clean_ttyname (const char *tty) clean_ttyname (char *tty)
{ {
const char *res = tty; char *res = tty;
if (strncmp (res, _PATH_DEV, strlen(_PATH_DEV)) == 0) if (strncmp (res, _PATH_DEV, strlen(_PATH_DEV)) == 0)
res += strlen(_PATH_DEV); res += strlen(_PATH_DEV);
@@ -62,10 +62,10 @@ clean_ttyname (const char *tty)
* Generate a name usable as an `ut_id', typically without `tty'. * Generate a name usable as an `ut_id', typically without `tty'.
*/ */
const char * char *
make_id (const char *tty) make_id (char *tty)
{ {
const char *res = tty; char *res = tty;
if (strncmp (res, "pts/", 4) == 0) if (strncmp (res, "pts/", 4) == 0)
res += 4; res += 4;

View File

@@ -1058,10 +1058,10 @@ int login_tty(int t)
* Clean the tty name. Return a pointer to the cleaned version. * Clean the tty name. Return a pointer to the cleaned version.
*/ */
static const char * static char *
clean_ttyname (const char *tty) clean_ttyname (char *tty)
{ {
const char *res = tty; char *res = tty;
if (strncmp (res, _PATH_DEV, strlen(_PATH_DEV)) == 0) if (strncmp (res, _PATH_DEV, strlen(_PATH_DEV)) == 0)
res += strlen(_PATH_DEV); res += strlen(_PATH_DEV);