diff options
author | rodrigc <rodrigc@FreeBSD.org> | 2014-06-23 22:31:28 +0000 |
---|---|---|
committer | rodrigc <rodrigc@FreeBSD.org> | 2014-06-23 22:31:28 +0000 |
commit | 95d8d7a8ec83f0dcf13e036e4b46b53f7cc6a182 (patch) | |
tree | 8c8bf69722e8a87fdf678c238a1aed6c77be0b5d /sbin | |
parent | f1ff231dbac5d2982001a60611cc0837baf2ba4d (diff) | |
download | FreeBSD-src-95d8d7a8ec83f0dcf13e036e4b46b53f7cc6a182.zip FreeBSD-src-95d8d7a8ec83f0dcf13e036e4b46b53f7cc6a182.tar.gz |
MFC r263795:
Strict value checking will cause problem.
Bay trail DN2820FYKH is supported on Linux but does not work on FreeBSD.
This behaviour is bug-compatible with Linux-3.13.5.
References:
http://d.hatena.ne.jp/syuu1228/20140326
http://lxr.linux.no/linux+v3.13.5/arch/x86/kernel/acpi/boot.c#L1094
Submitted by: syuu
PR: 187966
Diffstat (limited to 'sbin')
-rw-r--r-- | sbin/mount_nullfs/mount_nullfs.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/sbin/mount_nullfs/mount_nullfs.c b/sbin/mount_nullfs/mount_nullfs.c index e08599f..e92680b 100644 --- a/sbin/mount_nullfs/mount_nullfs.c +++ b/sbin/mount_nullfs/mount_nullfs.c @@ -103,18 +103,25 @@ main(int argc, char *argv[]) err(EX_USAGE, "%s", source); if (subdir(target, source) || subdir(source, target)) - errx(EX_USAGE, "%s (%s) and %s are not distinct paths", + errx(EX_USAGE, "%s (%s) and %s are not lldistinct paths", argv[0], target, argv[1]); + printf("Debug: 1\n"); build_iovec(&iov, &iovlen, "fstype", nullfs, (size_t)-1); build_iovec(&iov, &iovlen, "fspath", source, (size_t)-1); build_iovec(&iov, &iovlen, "target", target, (size_t)-1); build_iovec(&iov, &iovlen, "errmsg", errmsg, sizeof(errmsg)); + printf("Debug: 2, source: %zd target: %zdd\n", strlen(source), strlen(target)); if (nmount(iov, iovlen, 0) < 0) { - if (errmsg[0] != 0) + printf("Debug: 3\n"); + if (errmsg[0] != 0) { + printf("Debug 4\n"); err(1, "%s: %s", source, errmsg); - else + } + else { + printf("Debug 5\n"); err(1, "%s", source); + } } exit(0); } |