summaryrefslogtreecommitdiffstats
path: root/sys/compat
diff options
context:
space:
mode:
authormdf <mdf@FreeBSD.org>2010-09-10 16:42:16 +0000
committermdf <mdf@FreeBSD.org>2010-09-10 16:42:16 +0000
commitab3a8b533a824bceba3baf79642745d2b57f4c9d (patch)
treee9bea66185b980482df09793bce47717d6df59f2 /sys/compat
parentd0cd039a30daea0e7c8a5089793befb261d13de1 (diff)
downloadFreeBSD-src-ab3a8b533a824bceba3baf79642745d2b57f4c9d.zip
FreeBSD-src-ab3a8b533a824bceba3baf79642745d2b57f4c9d.tar.gz
Replace sbuf_overflowed() with sbuf_error(), which returns any error
code associated with overflow or with the drain function. While this function is not expected to be used often, it produces more information in the form of an errno that sbuf_overflowed() did.
Diffstat (limited to 'sys/compat')
-rw-r--r--sys/compat/linux/linux_ioctl.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/compat/linux/linux_ioctl.c b/sys/compat/linux/linux_ioctl.c
index b6de86a..07a281e 100644
--- a/sys/compat/linux/linux_ioctl.c
+++ b/sys/compat/linux/linux_ioctl.c
@@ -2220,7 +2220,7 @@ again:
addrs++;
}
- if (!sbuf_overflowed(sb))
+ if (sbuf_error(sb) == 0)
valid_len = sbuf_len(sb);
}
if (addrs == 0) {
@@ -2228,7 +2228,7 @@ again:
sbuf_bcat(sb, &ifr, sizeof(ifr));
max_len += sizeof(ifr);
- if (!sbuf_overflowed(sb))
+ if (sbuf_error(sb) == 0)
valid_len = sbuf_len(sb);
}
}
OpenPOWER on IntegriCloud