From 473828ca6aef18c574b8665ae484513e5592af03 Mon Sep 17 00:00:00 2001 From: Kevin O'Connor Date: Thu, 29 Oct 2020 23:54:17 -0400 Subject: command: Add command_decode_ptr() helper Add a helper function to convert from a string buffer passed in the args[] parameter to an actual pointer. This avoids all the callers needing to perfrom pointer manipulation. Signed-off-by: Kevin O'Connor --- src/command.h | 1 + 1 file changed, 1 insertion(+) (limited to 'src/command.h') diff --git a/src/command.h b/src/command.h index e7551ed7..67e595bc 100644 --- a/src/command.h +++ b/src/command.h @@ -71,6 +71,7 @@ enum { }; // command.c +void *command_decode_ptr(uint32_t v); uint8_t *command_parsef(uint8_t *p, uint8_t *maxend , const struct command_parser *cp, uint32_t *args); uint_fast8_t command_encodef(uint8_t *buf, const struct command_encoder *ce -- cgit v1.2.3-70-g09d2