diff options
author | Luke T. Shumaker <lukeshu@lukeshu.com> | 2025-04-19 09:14:20 -0600 |
---|---|---|
committer | Luke T. Shumaker <lukeshu@lukeshu.com> | 2025-04-19 12:53:42 -0600 |
commit | 09cac1d04e106b70ad4afde3b24df6d294d191b1 (patch) | |
tree | 602a9e60791f06dfa978824d819ede0b2977e9e5 /lib9p/core_include | |
parent | d81b0e1036aedb127c4033a187b671deaaca54c4 (diff) |
lib9p_srv: Separate the stat API from the network format
Diffstat (limited to 'lib9p/core_include')
-rw-r--r-- | lib9p/core_include/lib9p/core.h | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/lib9p/core_include/lib9p/core.h b/lib9p/core_include/lib9p/core.h index a82252b..572c68b 100644 --- a/lib9p/core_include/lib9p/core.h +++ b/lib9p/core_include/lib9p/core.h @@ -165,16 +165,6 @@ bool lib9p_Rmsg_marshal(struct lib9p_ctx *ctx, enum lib9p_msg_type typ, void *bo /* `struct lib9p_stat` helpers ************************************************/ -/** Assert that a `struct lib9p_stat` object looks valid. */ -static inline void lib9p_stat_assert(struct lib9p_stat stat) { - assert( ((bool)(stat.mode & LIB9P_DM_DIR )) == ((bool)(stat.qid.type & LIB9P_QT_DIR )) ); - assert( ((bool)(stat.mode & LIB9P_DM_APPEND)) == ((bool)(stat.qid.type & LIB9P_QT_APPEND)) ); - assert( ((bool)(stat.mode & LIB9P_DM_EXCL )) == ((bool)(stat.qid.type & LIB9P_QT_EXCL )) ); - assert( ((bool)(stat.mode & LIB9P_DM_AUTH )) == ((bool)(stat.qid.type & LIB9P_QT_AUTH )) ); - assert( ((bool)(stat.mode & LIB9P_DM_TMP )) == ((bool)(stat.qid.type & LIB9P_QT_TMP )) ); - assert( (stat.length == 0) || !(stat.mode & LIB9P_DM_DIR) ); -} - /** * Validate a message's `stat` structure. * |