X-Git-Url: https://git.decadent.org.uk/gitweb/?p=nfs-utils.git;a=blobdiff_plain;f=support%2Fnfs%2Fnfs_mntent.c;h=a5216fcf829cdf2e7e1c5524e0bb750eaa53fa43;hp=b407d6844cbe08f3aa040c4b5b24b7a2ecf7c824;hb=05f93b531d59df6e976d9b40c97b51546524040a;hpb=4e2bae795e5eaf9922f0b966ab5df64994c836a2 diff --git a/support/nfs/nfs_mntent.c b/support/nfs/nfs_mntent.c index b407d68..a5216fc 100644 --- a/support/nfs/nfs_mntent.c +++ b/support/nfs/nfs_mntent.c @@ -1,7 +1,7 @@ /* Private version of the libc *mntent() routines. */ /* Note slightly different prototypes. */ -/* 1999-02-22 Arkadiusz Mi¶kiewicz +/* 1999-02-22 Arkadiusz Miskiewicz * - added Native Language Support * * 2006-06-08 Amit Gud @@ -25,11 +25,12 @@ static unsigned char need_escaping[] = { ' ', '\t', '\n', '\\' }; static char * -mangle(const unsigned char *s) { +mangle(const char *arg) { + const unsigned char *s = (const unsigned char *)arg; char *ss, *sp; - int n; + unsigned int n; - n = strlen(s); + n = strlen(arg); ss = sp = xmalloc(4*n+1); while(1) { for (n = 0; n < sizeof(need_escaping); n++) { @@ -123,7 +124,7 @@ nfs_endmntent (mntFILE *mfp) { } int -nfs_addmntent (mntFILE *mfp, nfs_mntent_t *mnt) { +nfs_addmntent (mntFILE *mfp, struct mntent *mnt) { char *m1, *m2, *m3, *m4; int res; @@ -146,10 +147,10 @@ nfs_addmntent (mntFILE *mfp, nfs_mntent_t *mnt) { } /* Read the next entry from the file fp. Stop reading at an incorrect entry. */ -nfs_mntent_t * +struct mntent * nfs_getmntent (mntFILE *mfp) { static char buf[4096]; - static nfs_mntent_t me; + static struct mntent me; char *s; again: