[klibc] Re: [patch] trivial cleanup

Aaron Griffin
Sat, 01 Apr 2006 00:49:07 -0000

On 3/22/06, Aaron Griffin <aaronmgriffin@gmail.com>
wrote:
> remove 'NFS-Root' from an error message, and get rid of the
old_root
> check, as it's unused and fails if the target filesystem is mounted
> 'ro' for no good reason.
>
> --- kinit.c 2006-03-21 23:48:15.000000000 -0600
> +++ kinit.c 2006-03-22 01:09:39.000000000 -0600
> @@ -191,7 +191,7 @@
>         }
>     }
>     else if (!S_ISDIR(st.st_mode)) {
> -       fprintf(stderr, "NFS-Root: '%s' not a
directory\n", path);
> +       fprintf(stderr, "%s: '%s' not a directory\n",
progname, path);
>         exit(1);
>     }
>  }
> @@ -276,8 +276,6 @@
>
>     check_path("/root");
>     do_mounts(cmdc, cmdv);
> -   /* do_mounts cd's to /root so below tests /root/old_root */
> -   check_path("old_root");
>
>     if (mnt_procfs == 1)
>         umount2("/proc", 0);
>

Hi, I'm curious - klibc 1.3 still has the check for "old_root"
under
the mounted root, which is never used.  If the target filesystem is
mounted readonly, this check fails, and for no good reason.

Is there a reason why this is still in there that I'm missing?