svn commit: r337266 - head/sys/riscv/riscv
Ruslan Bukin
br at FreeBSD.org
Fri Aug 3 16:44:57 UTC 2018
Author: br
Date: Fri Aug 3 16:44:56 2018
New Revision: 337266
URL: https://svnweb.freebsd.org/changeset/base/337266
Log:
Return ENAMETOOLONG if the latest copied character
is not null terminator.
Sponsored by: DARPA, AFRL
Modified:
head/sys/riscv/riscv/copyinout.S
Modified: head/sys/riscv/riscv/copyinout.S
==============================================================================
--- head/sys/riscv/riscv/copyinout.S Fri Aug 3 16:35:37 2018 (r337265)
+++ head/sys/riscv/riscv/copyinout.S Fri Aug 3 16:44:56 2018 (r337266)
@@ -1,5 +1,5 @@
/*-
- * Copyright (c) 2015 Ruslan Bukin <br at bsdpad.com>
+ * Copyright (c) 2015-2018 Ruslan Bukin <br at bsdpad.com>
* All rights reserved.
*
* Portions of this software were developed by SRI International and the
@@ -133,5 +133,8 @@ ENTRY(copyinstr)
sd a5, 0(a3) /* done = count */
4: mv a0, x0 /* return 0 */
+ beqz a4, 5f
+ li a0, ENAMETOOLONG
+5:
ret
END(copyinstr)
More information about the svn-src-all
mailing list