Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(106)

Unified Diff: src/trusted/service_runtime/nacl_syscall_common.c

Issue 3687005: Report EMSGSIZE when appropriate for sendmsg (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client/
Patch Set: '' Created 10 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/trusted/desc/nrd_xfer.c ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/trusted/service_runtime/nacl_syscall_common.c
===================================================================
--- src/trusted/service_runtime/nacl_syscall_common.c (revision 3440)
+++ src/trusted/service_runtime/nacl_syscall_common.c (working copy)
@@ -1731,6 +1731,12 @@
*/
if (0 != (flags & NACL_DONT_WAIT) && NaClWouldBlock()) {
retval = -NACL_ABI_EAGAIN;
+ } else if (-NACL_ABI_EMSGSIZE == ssize_retval) {
+ /*
+ * Allow the caller to handle the case when imc_sendmsg fails because
+ * the message is too large for the system to send in one piece.
+ */
+ retval = -NACL_ABI_EMSGSIZE;
} else {
/*
* TODO(bsy): the else case is some mysterious internal error.
« no previous file with comments | « src/trusted/desc/nrd_xfer.c ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698