X-Git-Url: https://git.decadent.org.uk/gitweb/?p=nfs-utils.git;a=blobdiff_plain;f=support%2Fnfs%2Fnfs_mntent.c;h=a3fecfc05d8604c9334300c9a1a48fe0102d0a2c;hp=b407d6844cbe08f3aa040c4b5b24b7a2ecf7c824;hb=4c337e2131123c339bc4921779b57b69b77be2fd;hpb=4e2bae795e5eaf9922f0b966ab5df64994c836a2 diff --git a/support/nfs/nfs_mntent.c b/support/nfs/nfs_mntent.c index b407d68..a3fecfc 100644 --- a/support/nfs/nfs_mntent.c +++ b/support/nfs/nfs_mntent.c @@ -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; - 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: