summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib9p/core_include/lib9p/core.h12
-rw-r--r--lib9p/srv_include/lib9p/srv.h2
2 files changed, 5 insertions, 9 deletions
diff --git a/lib9p/core_include/lib9p/core.h b/lib9p/core_include/lib9p/core.h
index 4941220..1f875d4 100644
--- a/lib9p/core_include/lib9p/core.h
+++ b/lib9p/core_include/lib9p/core.h
@@ -98,11 +98,7 @@ void fmt_print_lib9p_msg(lo_interface fmt_dest w, struct lib9p_ctx *ctx, enum li
* number may be larger than net_bytes due to (1) struct padding, (2)
* array pointers.
*
- * Emits an error (return -1, set ctx->err_num and ctx->err_msg) if
- * either the message type is unknown, or if net_bytes is too short
- * for that message type, or if an invalid string (invalid UTF-8,
- * contains a nul-byte) is encountered.
- *
+ * @param ctx : negotiated protocol parameters, where to record errors
* @param net_bytes : the complete request, starting with the "size[4]"
*
* @return required size, or -1 on error
@@ -110,7 +106,7 @@ void fmt_print_lib9p_msg(lo_interface fmt_dest w, struct lib9p_ctx *ctx, enum li
* @errno L_EOPNOTSUPP: message is an R-message
* @errno L_EOPNOTSUPP: message has unknown type
* @errno L_EBADMSG: message is wrong size for content
- * @errno L_EBADMSG: message contains invalid UTF-8
+ * @errno L_EBADMSG: message contains invalid UTF-8, or the UTF-8 contains a nul-byte
* @errno L_EBADMSG: message contains a bitfield with unknown bits
* @errno L_EMSGSIZE: would-be return value overflows SSIZE_MAX
*/
@@ -142,9 +138,9 @@ void lib9p_Tmsg_unmarshal(struct lib9p_ctx *ctx, uint8_t *net_bytes,
*
* @param ctx : negotiated protocol parameters, where to record errors
* @param typ : the message type
- * @param msg : the message to encode
+ * @param msg : the message to encode (`struct lib9p_msg_XXXX` according to `typ`)
*
- * @return ret_bytes : the buffer to encode to, must be at be at least ctx->max_msg_size bytes
+ * @return ret : the buffer to encode to
* @return whether there was an error (false=success, true=error)
*
* @errno L_ERANGE: reply does not fit in ctx->max_msg_size
diff --git a/lib9p/srv_include/lib9p/srv.h b/lib9p/srv_include/lib9p/srv.h
index eb87d6f..89dc986 100644
--- a/lib9p/srv_include/lib9p/srv.h
+++ b/lib9p/srv_include/lib9p/srv.h
@@ -185,7 +185,7 @@ LO_INTERFACE(lib9p_srv_fio); /*>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>*/
LO_FUNC(void , iofree ) \
/** \
* Return the idx-th dirent. idx will always be either 0 or \
- * prev_idx+1. A dirrent with an empty name signals EOF. The string \
+ * prev_idx+1. A dirent with an empty name signals EOF. The string \
* must remain valid until the next dread() call or iofree(). \
*/ \
LO_FUNC(struct lib9p_srv_dirent , dread , struct lib9p_srv_ctx *, \