diff options
author | Ulrich Drepper <drepper@redhat.com> | 1999-07-26 01:47:15 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 1999-07-26 01:47:15 +0000 |
commit | 63f7cb448b3958d7520d7eab6d092d7e6f11f1d9 (patch) | |
tree | 6e52259de48fb1cfad2c79a858eca2530ce01dbe /misc/mntent_r.c | |
parent | b0b422e85da7e35cc989d177445912383fb7eda1 (diff) | |
download | glibc-63f7cb448b3958d7520d7eab6d092d7e6f11f1d9.tar glibc-63f7cb448b3958d7520d7eab6d092d7e6f11f1d9.tar.gz glibc-63f7cb448b3958d7520d7eab6d092d7e6f11f1d9.tar.bz2 glibc-63f7cb448b3958d7520d7eab6d092d7e6f11f1d9.zip |
Update.
* misc/tst-mntent.c: Add test case for addmntent and getmntent.
Diffstat (limited to 'misc/mntent_r.c')
-rw-r--r-- | misc/mntent_r.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/misc/mntent_r.c b/misc/mntent_r.c index 43cb3f732a..6d46abbd95 100644 --- a/misc/mntent_r.c +++ b/misc/mntent_r.c @@ -162,14 +162,18 @@ weak_alias (__getmntent_r, getmntent_r) while (*rp != '\0') \ if (*rp == ' ' || *rp == '\t' || *rp == '\\') \ break; \ + else \ + ++rp; \ \ if (*rp != '\0') \ { \ /* In the worst case the length of the string can increase to \ founr times the current length. */ \ - char *wp = (char *) alloca (strlen (name) * 4 + 1); \ + char *wp; \ \ rp = name; \ + name = wp = (char *) alloca (strlen (name) * 4 + 1); \ + \ do \ if (*rp == ' ') \ { \ @@ -193,8 +197,6 @@ weak_alias (__getmntent_r, getmntent_r) else \ *wp++ = *rp; \ while (*rp++ != '\0'); \ - \ - name = wp; \ } \ } while (0) |